1 // Fork a binary tree of processes and display their structure.
7 void forktree(const char *cur
);
10 forkchild(const char *cur
, char branch
)
14 if (strlen(cur
) >= DEPTH
)
17 snprintf(nxt
, DEPTH
+1, "%s%c", cur
, branch
);
25 forktree(const char *cur
)
27 cprintf("%04x: I am '%s'\n", sys_getenvid(), cur
);