Bootscript Updates

Bryan Kadzban bryan at
Thu Sep 16 16:11:28 PDT 2004

Nathan Coulson wrote:
> I need a simple C program to fake a daemon.
> It should write it's PID# to /var/run/, then go into the 
> background doing while(1) {sleep();}  Would be neat if it can print 
> out what signals it receives as well (;  [and option to ignore the 
> stop signal]

I'm bored.  :-P

No option to ignore the stop signal (SIGSTOP can't be ignored; maybe you
meant SIGTERM?), but whatever.  It prints the signal number, not the
name, but oh well.

Modeled on ESR's daemon code (from his Unix cookbook).

Compile with a "make test".
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: test.c
URL: <>

More information about the lfs-dev mailing list