[Sysfence-commit] sysfence sysfence.c,1.16,1.17
Status: Alpha
Brought to you by:
emes
|
From: mkoperto <mko...@us...> - 2004-05-24 22:23:17
|
Update of /cvsroot/sysfence/sysfence In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3923 Modified Files: sysfence.c Log Message: + process titles Index: sysfence.c =================================================================== RCS file: /cvsroot/sysfence/sysfence/sysfence.c,v retrieving revision 1.16 retrieving revision 1.17 diff -u -d -r1.16 -r1.17 --- sysfence.c 23 May 2004 20:52:22 -0000 1.16 +++ sysfence.c 24 May 2004 22:23:05 -0000 1.17 @@ -33,6 +33,7 @@ #include "communication.h" #include "sighandlers.h" #include "cp2memory.h" +#include "processtitle.h" const char *usage = "sysfence v0.11, 01-03-2004\n" @@ -134,6 +135,10 @@ /* child */ if (pid == 0) { + /* process title */ + initproctitle (argc, argv); + setproctitle (RULE_PROCESS, STATE_NORMAL, (*(shmruletab + i))->name); + /* one child process one ruleset */ rule_watch_loop (*(shmruletab + i)); } else /* parent */ @@ -141,6 +146,10 @@ /* start handling signals */ signal_init (); + /* process title */ + initproctitle (argc, argv); + setproctitle (MAIN_PROCESS, 0, NULL); + /* parent goes into data-providing loop */ res_probe_loop (main_db); } |