Arvinn Løkkebakken wrote:
> Hi. Thanks for a fine product.
>
> I have set DAEMON=1 in the config.
> I have some troubles with running policyd as a daemon though. Every time
> after starting policyd in a ssh terminal I am not able to end the ssh
> terminal when logging out afterwards. The ssh terminal lives forever
> until I kill the policyd process that was started from within it, or
> until I kill the sshd process itself.
> Does anybody else experience the same problem?
>
> OS:. CentOS 5
> Policyd 1.82.
>
> Regards,
> Arvinn
>
A colleague of mine looked over the code and did the following changes.
Here's the patch I created of the the changes:
--- sockets.c.orig 2007-08-20 08:42:05.000000000 +0200
+++ sockets.c 2007-12-04 09:55:34.000000000 +0100
@@ -452,11 +452,11 @@
_exit(0); /* child 1 terminates */
/* child 2 continues */
- if(nochdir)
+ if(!nochdir)
chdir("/"); /* change working directory */
/* close off all file descriptors */
- if(noclose)
+ if(!noclose)
for(i=0;i<64;i++)
close(i);
.. claiming that the code did not seem logically correct before. If
noclose is set, why close? Anyway, with these changes my problem is gone :)
Cami, I'll try your patch too. Thanks.
Arvinn
-------------------------------------------------------------------------
SF.Net email is sponsored by: The Future of Linux Business White Paper
from Novell. From the desktop to the data center, Linux is going
mainstream. Let it simplify your IT future.
http://altfarm.mediaplex.com/ad/ck/8857-50307-18918-4
_______________________________________________
policyd-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/policyd-users