Lines Matching defs:cur
78 struct pid *cur, *p;
91 cur = malloc(sizeof(struct pid));
92 if (cur == NULL)
111 cur->command = checked_strdup(command);
135 cur->outfp = fdopen(outfds[0], "r");
140 cur->pid = pid;
141 SLIST_INSERT_HEAD(&pidlist, cur, next);
143 return (cur->outfp);
149 struct pid *cur, *last = NULL;
156 SLIST_FOREACH(cur, &pidlist, next) {
157 if (cur->outfp == iop)
159 last = cur;
161 if (cur == NULL) {
169 fclose(cur->outfp);
172 pid = wait4(cur->pid, &status, 0, NULL);
177 cur->command, pid, WTERMSIG(status));
183 cur->command, pid, WEXITSTATUS(status));
187 log_debugx("\"%s\", pid %d, terminated gracefully", cur->command, pid);
189 free(cur->command);
190 free(cur);