svn commit: trunk/busybox/init

landley at busybox.net landley at busybox.net
Wed Mar 22 17:39:14 UTC 2006


Author: landley
Date: 2006-03-22 09:39:13 -0800 (Wed, 22 Mar 2006)
New Revision: 14606

Log:
Patch from Rogelio Serrano to defer checking whether the tty exists until
we actually need to spawn something on it.


Modified:
   trunk/busybox/init/init.c


Changeset:
Modified: trunk/busybox/init/init.c
===================================================================
--- trunk/busybox/init/init.c	2006-03-22 17:28:37 UTC (rev 14605)
+++ trunk/busybox/init/init.c	2006-03-22 17:39:13 UTC (rev 14606)
@@ -620,7 +620,9 @@
 	for (a = init_action_list; a; a = tmp) {
 		tmp = a->next;
 		if (a->action == action) {
-			if (a->action & (SYSINIT | WAIT | CTRLALTDEL | SHUTDOWN | RESTART)) {
+			if (access(a->terminal, R_OK | W_OK)) {
+				delete_init_action(a);
+			} else if (a->action & (SYSINIT | WAIT | CTRLALTDEL | SHUTDOWN | RESTART)) {
 				waitfor(a);
 				delete_init_action(a);
 			} else if (a->action & ONCE) {
@@ -815,9 +817,6 @@
 	if (*cons == '\0')
 		cons = console;
 
-	/* do not run entries if console device is not available */
-	if (access(cons, R_OK | W_OK))
-		return;
 	if (strcmp(cons, bb_dev_null) == 0 && (action & ASKFIRST))
 		return;
 




More information about the busybox-cvs mailing list