Lines Matching refs:current
76 static void create_node(struct cil_tree_node **node, struct cil_tree_node *current, uint32_t line, uint32_t hll_offset, void *value)
79 (*node)->parent = current;
86 static void insert_node(struct cil_tree_node *node, struct cil_tree_node *current)
88 if (current->cl_head == NULL) {
89 current->cl_head = node;
91 current->cl_tail->next = node;
93 current->cl_tail = node;
96 static int add_hll_linemark(struct cil_tree_node **current, uint32_t *hll_offset, uint32_t *hll_expand, struct cil_stack *stack, char *path)
131 *current = (*current)->parent;
139 create_node(&node, *current, tok.line, *hll_offset, NULL);
140 insert_node(node, *current);
141 *current = node;
143 create_node(&node, *current, tok.line, *hll_offset, CIL_KEY_SRC_INFO);
144 insert_node(node, *current);
146 create_node(&node, *current, tok.line, *hll_offset, hll_type);
147 insert_node(node, *current);
155 create_node(&node, *current, tok.line, *hll_offset, cil_strpool_add(tok.value));
156 insert_node(node, *current);
169 create_node(&node, *current, tok.line, *hll_offset, cil_strpool_add(tok.value));
170 insert_node(node, *current);
193 static void add_cil_path(struct cil_tree_node **current, char *path)
197 create_node(&node, *current, 0, 0, NULL);
198 insert_node(node, *current);
199 *current = node;
201 create_node(&node, *current, 0, 0, CIL_KEY_SRC_INFO);
202 insert_node(node, *current);
204 create_node(&node, *current, 0, 0, CIL_KEY_SRC_CIL);
205 insert_node(node, *current);
207 create_node(&node, *current, 0, 0, cil_strpool_add("1"));
208 insert_node(node, *current);
210 create_node(&node, *current, 0, 0, path);
211 insert_node(node, *current);
221 struct cil_tree_node *current = NULL;
234 current = tree->root;
236 add_cil_path(¤t, path);
242 rc = add_hll_linemark(¤t, &hll_offset, &hll_expand, stack, path);
253 create_node(&node, current, tok.line, hll_offset, NULL);
254 insert_node(node, current);
255 current = node;
263 current = current->parent;
275 create_node(&node, current, tok.line, hll_offset, cil_strpool_add(tok.value));
276 insert_node(node, current);