Thread: catching signals and process IDs

  1. #1
    Registered User
    Join Date
    Sep 2008
    Posts
    6

    catching signals and process IDs

    Hi all

    Have a small problem and need a solution.

    We have two processes that were created in our main program. We need them to be able to send signals to each other. One child knows the pid of the other, and we need to send a signal from the other child 1 to child 2 so child 2 can learn the pid of child 1. Is there a way to catch this signal and learn the pid this way. Thanks.

  2. #2
    Registered User
    Join Date
    Oct 2006
    Location
    Canada
    Posts
    1,243
    if your talking about unix machines, then im pretty sure the "kill" function is used to only signal another process (id). any communication between the two processes would need to be done through files or (named or unnamed) pipes or sockets. unnamed pipes would probably be easiest and ideal.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 3
    Last Post: 10-15-2008, 09:24 AM
  2. process programming
    By St0rM-MaN in forum Linux Programming
    Replies: 2
    Last Post: 09-15-2007, 07:53 AM
  3. Problem with signals
    By kahad in forum C Programming
    Replies: 9
    Last Post: 12-07-2006, 10:42 AM
  4. Signals in Unix Solaris
    By heljy in forum C Programming
    Replies: 0
    Last Post: 03-25-2002, 03:20 PM
  5. Signals in Unix Solaris
    By heljy in forum Linux Programming
    Replies: 0
    Last Post: 03-24-2002, 07:00 PM