4 umain(int argc
, char **argv
)
8 cprintf("initsh: running sh\n");
10 // being run directly from kernel, so no file descriptors open yet
12 if ((r
= opencons()) < 0)
13 panic("opencons: %e", r
);
15 panic("first opencons used fd %d", r
);
16 if ((r
= dup(0, 1)) < 0)
19 cprintf("init: starting sh\n");
20 r
= spawnl("/sh", "sh", (char*)0);
22 cprintf("init: spawn sh: %e\n", r
);