[Raw Msg Headers][Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

No Subject




Newsgroups: local.mailgate.zmailer
Path: acli
From: acli@www.mingpaoxpress.com (Ambrose Li)
Subject: Re: strange scheduler log (again)
Distribution: local
Organization: Ming Pao Daily News (Canada)
Message-ID: <E2B77K.G32@www.mingpaoxpress.com>
References: <Pine.LNX.3.91.961209004923.3312A-100000@monet.mingpaoxpress.com> <d6wiv6b8qbp.fsf@lupinella.troll.no>
Date: Thu, 12 Dec 1996 16:30:56 GMT

In article <d6wiv6b8qbp.fsf@lupinella.troll.no>,
Arnt Gulbrandsen  <arnt@gulbrandsen.priv.no> wrote:
>> 	...
>>         libc.so.4 (DLL Jump 4.6pl27) => /lib/libc.so.4.6.27
>
>For some reason you're exec()'ing a program and giving it a null argv.
>(The above message is shown if **argv == '\0'.)

Turns out that we need the following patch for the scheduler:

--- scheduler/transport.c.orig	Thu Oct 31 09:53:14 1996
+++ scheduler/transport.c	Thu Dec 12 11:15:09 1996
@@ -690,7 +690,7 @@
 	      if (rc == 0) { /* Child! */
 		close(querysocket);
 		qprint(i);
-		execl("/bin/false",NULL);
+		execl("/bin/false","false",NULL);
 		_exit(0);
 	      }
 	      /* if (rc > 0)
@@ -751,7 +751,7 @@
 	      int pid = fork();
 	      if (pid == 0) {
 		qprint(n);
-		execl("/bin/false",NULL);
+		execl("/bin/false","false",NULL);
 		_exit(0);
 	      }
 	      close(n);

I still don't know why this doesn't happen on Linux box at home.
But that's irrelevant now.

Now another question: Why do we exec /bin/false and then _exit(0)?
Wouldn't _exit(1) do the same thing? Please excuse my ignorance if
this is obvious.

-- 
--
Ambrose Li. acli@mingpaoxpress.com. Ming Pao Newspapers (Canada) Ltd., EDP
department. 1355 Huntingwood Drive, Scarborough, Ontario, M1S 3J1, Canada.
Voice +1 416 321 0088 x272 Fax +1 416 321 9663.