X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fruntime%2Fruntime.c;h=6900e50396f6da6fe54d42e93480da76020dfa33;hb=a0a413499415738d23cc40baa44e9c404af54a94;hp=ad6a34b63fe74c0c67ff3f2931aa01f6b97d1526;hpb=0e2c926fea68a32c8ec58f12daa0c2b5befef1d4;p=sbcl.git diff --git a/src/runtime/runtime.c b/src/runtime/runtime.c index ad6a34b..6900e50 100644 --- a/src/runtime/runtime.c +++ b/src/runtime/runtime.c @@ -468,13 +468,14 @@ static void /* noreturn */ parent_loop(void) maybe_gc_pending=0; while(all_threads && (pid=waitpid(-1,&status,__WALL|WUNTRACED))) { struct thread *th; + int real_errno=errno; while(maybe_gc_pending) parent_do_garbage_collect(); if(pid==-1) { - if(errno == EINTR) { + if(real_errno == EINTR) { continue; } - if(errno == ECHILD) break; - fprintf(stderr,"waitpid: %s\n",strerror(errno)); + if(real_errno == ECHILD) break; + fprintf(stderr,"waitpid: %s\n",strerror(real_errno)); continue; } th=find_thread_by_pid(pid);