logo       

daemons terminating: msg#00181

lib.uclibc.general

Subject: daemons terminating

I'm having problems with the daemon-function on a 48 Mhz motorola 860.
It seems like parent process terminates before the child process has had time
to become session leader. Am I the only one with this problem?
If a apply following patch everything works,

/Bjorn Andersson



--- uClibc-0.9.14/libc/unistd/daemon.c.orig Tue Oct 29 20:15:34 2002
+++ uClibc-0.9.14/libc/unistd/daemon.c Tue Oct 29 20:16:22 2002
@@ -42,6 +42,7 @@
case 0:
break;
default:
+ sleep(1); /* give child time to become session leader */
_exit(0);
}


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise