This is the mail archive of the mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Cygrunsrv and spawned processes

On Dec  4 16:33, Frank Seesink wrote:
> Igor Pechtchanski wrote:
> >On Thu, 4 Dec 2003, Frank Seesink wrote:


> This tells me that cygrunsrv is not giving you a full environment within 
> which to run the app.  I've looked into spawnlp() and the P_NOWAIT mode, 

It gives you the system environment plus everything specified by the -e
option.  Where else should it get its environment from?

> Anyway, I'm grasping at straws.  I'd just love to get this working 
> properly without leftover processes building up.  Any more 
> thoughts/ideas I can try?  I'll give anything a whack. :-)

I'm guessing that jabber is by default using fork/exec.  Why didn't
you just leave it this way?

A look into the jabberd sources should give a hint which signal is
expected.  In theory there should be a signal handler which then cares
for jabberd's child process.  Assuming it is a SIGHUP handler, send
SIGHUP from cygrunsrv.  Cygrunsrv has no idea about child processes
started from it's inferior process.  It's the responsibility of that
process to care for its children.  This is different from the situation
in the shell where a Ctrl-C results in a SIGINT sent to all processes
not detached from the console.  A process started with spawn(_P_NOWAIT)
is not detached from the console.

Debugging jabberd might give a clue, too.


Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Developer                      
Red Hat, Inc.

Unsubscribe info:
Problem reports:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]