linux-c-programming.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ron Michael Khu <ronkhu@ntsp.nec.co.jp>
To: Suma Choudhary <sumac@myw.ltindia.com>,
	linux-c-programming <linux-c-programming@vger.kernel.org>
Subject: Re: fork + signal
Date: Fri, 29 Jul 2005 11:03:12 +0800	[thread overview]
Message-ID: <42E99C70.3090807@hq.ntsp.nec.co.jp> (raw)
In-Reply-To: <s2e9e5b6.077@EMAIL>

state-machine processing problems?

perhaps the mother process was not yet finished performing the function 
for processing the "card insertion message"
when the child process raised a SIGCHLD... perhaps a system call or a 
task done by the parent process was interrupted when the SIGCHLD
was received by the signal handler..

aside from doing a "fork" (and an "exec"), what are other tasks are done 
whenever a card insertion message is received??

can u show some code? both for the parent and child processes



Suma Choudhary wrote:

>Sorry for being so vague!
>OK the situation is like this:
>I've a process which after receiving a card insertion message  spawns another process.
>Now when the insertion and removal of card is done at a fast rate, the spawning of the child stops after certain time:-(
>This when checked with a slower rate works fine.
>
>When the card is removed the child process detects it and kills itself.
>THe parent gets a SIGCHLD and "waits" on the child.
>
>Do u see any problem here......should I disable the SIGCHLD before spawning the child?
>
>
>Thanks for taking the time to consider it.
>
>Regards
>suma
>
>  
>
>>>>r_zaca <r_zaca@ig.com.br> 07/28/05 22:03 PM >>>
>>>>        
>>>>
> Suma, 
>
> How could a child process send a signal if it is not already created? 
>
>  
>
>>hi all 
>>I have this doubt of what happens when a process is still on the way >of 
>>forking(+ maybe exec further) a child and there comes a sigchld >signal. 
>>(Of course assuming that theres a signal handler for the sigchld >signal.) 
>>    
>>
>
>  
>
>>hopeful of getting an answer 
>>regards 
>>suma 
>>    
>>
>
>-
>To unsubscribe from this list: send the line "unsubscribe linux-c-programming" in
>the body of a message to majordomo@vger.kernel.org
>More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
>
>  
>


  reply	other threads:[~2005-07-29  3:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-29  2:45 fork + signal Suma Choudhary
2005-07-29  3:03 ` Ron Michael Khu [this message]
2005-07-29  4:42   ` Amit Dang
  -- strict thread matches above, loose matches on Subject: below --
2005-07-29  7:55 Suma Choudhary
2005-07-28 16:21 r_zaca
2005-07-28 13:51 Suma Choudhary

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=42E99C70.3090807@hq.ntsp.nec.co.jp \
    --to=ronkhu@ntsp.nec.co.jp \
    --cc=linux-c-programming@vger.kernel.org \
    --cc=sumac@myw.ltindia.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).