From: John Hodge (sonata) Date: Sat, 19 Jan 2013 11:31:03 +0000 (+0800) Subject: Kernel - Opened stdin/stdout on VT0 for init X-Git-Tag: rel0.15~598^2~49 X-Git-Url: https://git.ucc.asn.au/?a=commitdiff_plain;h=a68be7cc872401b89ec97b763603484d572e4b4b;p=tpg%2Facess2.git Kernel - Opened stdin/stdout on VT0 for init --- diff --git a/KernelLand/Kernel/system.c b/KernelLand/Kernel/system.c index 9224db55..7938723a 100644 --- a/KernelLand/Kernel/system.c +++ b/KernelLand/Kernel/system.c @@ -48,6 +48,8 @@ void System_Init(char *CommandLine) if(Proc_Clone(CLONE_VM|CLONE_NOUSER) == 0) { const char *args[] = {gsInitBinary, 0}; + VFS_Open("/Devices/VTerm/0", VFS_OPENFLAG_READ|VFS_OPENFLAG_USER); // 0: stdin + VFS_Open("/Devices/VTerm/0", VFS_OPENFLAG_WRITE|VFS_OPENFLAG_USER); // 1: stdout Proc_Execve(gsInitBinary, args, &args[1], 0); Log_KernelPanic("System", "Unable to spawn init '%s'", gsInitBinary); }