Lines Matching refs:cmd_p

127 cmd_destroy(cmd_t * cmd_p)
129 if (!cmd_p)
132 if (!queue_isempty(&cmd_p->qn))
133 (void) queue_remove(&cmd_p->qn);
135 if (!cmd_p->isnamed)
136 expr_destroy(cmd_p->expr.expr_p);
138 free(cmd_p);
151 cmd_t *cmd_p; in cmd_list() local
155 cmd_p = (cmd_t *) & g_cmdlist; in cmd_list()
156 while ((cmd_p = (cmd_t *) queue_next(&g_cmdlist, &cmd_p->qn))) { in cmd_list()
157 switch (cmd_p->kind) { in cmd_list()
182 if (cmd_p->kind == CMD_CONNECT) { in cmd_list()
183 (void) printf("&%s ", cmd_p->fcnname_p); in cmd_list()
185 if (!cmd_p->isnamed) { in cmd_list()
186 expr_print(stdout, cmd_p->expr.expr_p); in cmd_list()
202 cmd_t *cmd_p; in cmd_traverse() local
205 cmd_p = (cmd_t *) & g_cmdlist; in cmd_traverse()
206 while ((cmd_p = (cmd_t *) queue_next(&g_cmdlist, &cmd_p->qn))) { in cmd_traverse()
210 if (!cmd_p->isnamed) { in cmd_traverse()
211 expr_p = cmd_p->expr.expr_p; in cmd_traverse()
214 if (cmd_p->kind == CMD_CONNECT) { in cmd_traverse()
215 fcn_p = fcn_find(cmd_p->fcnname_p); in cmd_traverse()
222 cmd_p->kind, in cmd_traverse()
223 fcn_p, cmd_p->isnew, calldata_p); in cmd_traverse()
236 cmd_callback(cmd_t *cmd_p, cmd_traverse_func_t percmdfunc, void *calldata_p) in cmd_callback() argument
242 if (!cmd_p->isnamed) { in cmd_callback()
243 expr_p = cmd_p->expr.expr_p; in cmd_callback()
246 if (cmd_p->kind == CMD_CONNECT) { in cmd_callback()
247 fcn_p = fcn_find(cmd_p->fcnname_p); in cmd_callback()
253 err = (*percmdfunc) (expr_p, cmd_p->kind, fcn_p, cmd_p->isnew, in cmd_callback()
267 cmd_t *cmd_p; in cmd_mark() local
269 cmd_p = (cmd_t *) & g_cmdlist; in cmd_mark()
270 while ((cmd_p = (cmd_t *) queue_next(&g_cmdlist, &cmd_p->qn))) { in cmd_mark()
271 cmd_p->isnew = B_FALSE; in cmd_mark()
283 cmd_t *cmd_p; in cmd_delete() local
286 cmd_p = (cmd_t *) & g_cmdlist; in cmd_delete()
287 while ((cmd_p = (cmd_t *) queue_next(&g_cmdlist, &cmd_p->qn))) { in cmd_delete()
289 cmd_destroy(cmd_p); in cmd_delete()