Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

fork

Status
Not open for further replies.

kenguru

Programmer
May 14, 2004
173
RO
If I have the following code:
{..
fork();fork()
if (fork()) then {}

..
}
What does happend along the lines? The first fork creates a child, but in the line there is no specification that what happend with the child, so the next line where is it place? In the child? In the parent?
Please explain for me.
Thank You,
Kenguru
 
It's not a course assigment. We are learning about forks and i didn't understand this example given by the profe, and i would like to understand it if i got something asame at the exame. So, could You explain it to me?
Kenguru
 
Well, it is not a programming forum, but since we got this far:

There are lots of children in this example, but you aren't doing anything useful with any of them. I'm not sure if that was the point of the example, and your question as phrased makes no sense to me.

But really - take this to a programming forum.

Tony Lawrence
Linux/Unix/Mac OS X Resources
 
See if this helps: thread205-1035849

If not, that'd be a better forum in which to ask your question.
 
Thanks a lot for pointing me this forum, this help me the most.
Kenguru
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top