Now with Yuru's patch we have intelligence to walk down /proc looking
for a PID before firing a new one.

If you want, you can test the latest version in experimental.


On Wednesday 10 September 2014 04:24 PM, Ritesh Raj Sarraf wrote:
> One approach that I just documented in the NEWS file is to use a
> shutdown script. In KDE, we have ~/.kde/shutdown/ for this. I'll look
> into your suggestion later. Right now I need to get my other packages
> in shape for Jessie.
>
> On Wed, Sep 10, 2014 at 4:21 PM, Laurent Bigonville <bi...@debian.org
> <mailto:bi...@debian.org>> wrote:
>
>     Le Wed, 10 Sep 2014 15:32:10 +0530,
>     Ritesh Raj Sarraf <r...@researchut.com <mailto:r...@researchut.com>>
>     a écrit :
>
>     > On Monday 01 September 2014 05:12 PM, Laurent Bigonville wrote:
>     > >> >Give me your thoughts here. The daemon gets started as the user
>     > >> >logs in. I think I made it follow some fdo xdg stuff. Is there
>     > >> >something similar for logout ??
>     > >> >daemon(0,0);
>     > > Are you sure that application started by xdg autostart can
>     actually
>     > > fork? I've the feeling that gnome-session is loosing track of the
>     > > PID of the process (but this is a wild guess)
>     >
>     >
>     > I have no idea about desktops. That's why I asked you.
>     >
>     > The other approach would be to do a check in within the daemon
>     > itself. It would mean walking down the /proc file system and
>     look for
>     > the proc name. Ugly, but may work. May look at it in the future.
>
>     I tried removing the call to daemon(3), same issue.
>
>     Could be related to the use of system() command?
>
>     Quoting the system(3) manpage:
>
>            As mentioned, system() ignores SIGINT and SIGQUIT.  This
>     may make programs that call it from a loop uninterruptible, unless
>     they take care themselves to check the exit  sta‐
>            tus of the child.  For example:
>                while (something) {
>                    int ret = system("foo");
>
>                    if (WIFSIGNALED(ret) &&
>                        (WTERMSIG(ret) == SIGINT || WTERMSIG(ret) ==
>                    SIGQUIT)) break;
>                }
>
>
>
>
> -- 
> Ritesh Raj Sarraf
> RESEARCHUT - http://www.researchut.com
> "Necessity is the mother of invention."


-- 
Ritesh Raj Sarraf
RESEARCHUT - http://www.researchut.com
"Necessity is the mother of invention."


Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to