From 235e6e0e3949c459c58e15dc3dbe8ea0e1073976 Mon Sep 17 00:00:00 2001 From: "Anton V. Boyarshinov" Date: Fri, 19 Nov 2010 23:28:16 +0300 Subject: [PATCH] 20090301-alt13.1 - silly bug in waiting fixed --- log.c | 3 ++- propagator.spec | 5 ++++- stage1.c | 1 + 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/log.c b/log.c index d98f288..759bad3 100644 --- a/log.c +++ b/log.c @@ -72,7 +72,8 @@ void open_log(void) if (!IS_TESTING) { for(i=0; i < timeout; i++ ) { logfile = fopen("/dev/tty3", "w"); - if(logfile > -1) break; + if(logfile != NULL) break; + fprintf(stderr,"\rwaiting for /dev/tty3: %d",i); sleep(1); } if (!logfile) diff --git a/propagator.spec b/propagator.spec index 870763d..59f566c 100644 --- a/propagator.spec +++ b/propagator.spec @@ -3,7 +3,7 @@ Name: propagator Version: 20090301 -Release: alt13 +Release: alt13.1 Summary: 'Early userspace' set of binaries License: GPL @@ -39,6 +39,9 @@ make %{?_with_shell:WITH_SHELL=t} %{?_with_splash:WITH_SPLASH=t} libdir=%_libdir %_libdir/%name %changelog +* Fri Nov 19 2010 Anton V. Boyarshinov 20090301-alt13.1 +- silly bug in waiting fixed + * Thu Nov 18 2010 Anton V. Boyarshinov 20090301-alt13 - Wait for tty[23]. It seems that is also fixes drives detection on el-smp diff --git a/stage1.c b/stage1.c index 9219f49..fc461d3 100644 --- a/stage1.c +++ b/stage1.c @@ -120,6 +120,7 @@ static void spawn_shell(void) for(i=0; i < timeout; i++ ) { fd = open("/dev/tty2", O_RDWR); if(fd > -1) break; + fprintf(stderr,"waiting for /dev/tty2: %d\n",i); sleep(1); } if (fd == -1) {