while(1) fork() problem
hello concerned
while(1)fork();
why this code has a problem is quite understood .
what can be the solution ?
---------------------------------
Get your own web address for just $1.99/1st yr. We'll help. Yahoo! Small Business.
_______________________________________________
Kernel-janitors mailing list
[email protected]
https://lists.osdl.org/mailman/listinfo/kernel-janitors
Quoted 5 lines · nikhil mishra
hello concerned
while(1)fork();
why this code has a problem is quite understood .
what can be the solution ?
Take a look at man ulimit.
regards,
dan carpenter
_______________________________________________
Kernel-janitors mailing list
[email protected]
https://lists.osdl.org/mailman/listinfo/kernel-janitors
Quoted 5 lines · nikhil mishra
hello concerned
while(1)fork();
why this code has a problem is quite understood .
what can be the solution ?
"Don't do it." is the other solution.
Bernd
Signature · 8 lines
Firmix Software GmbH http://www.firmix.at/
mobil: +43 664 4416156 fax: +43 1 7890849-55
Embedded Linux Development and Services
_______________________________________________
Kernel-janitors mailing list
[email protected]
https://lists.osdl.org/mailman/listinfo/kernel-janitorsQuoted 4 lines · On Thu, 14 Sep 2006 20:58:12 -0700 (PDT) nikhil mishra <[email protected]>…
hello concerned
while(1)fork();
why this code has a problem is quite understood .
Well that should be obvious. Fork creates a copy of the process. while(1) has no loop limit. What do you think happens if you keep copying the process? Whats worse, when those running copies reach the edge of the loop they themselves fork()... Very soon something has to give.
Quoted 1 line
what can be the solution ?
Change while(1) to while(1=2).
Signature · 7 lines
Regards, Ed :: http://www.linuxwarez.co.uk proud unix person Vin Diesel stole my frog. Him name is Hopkin Green Frog. _______________________________________________ Kernel-janitors mailing list [email protected] https://lists.osdl.org/mailman/listinfo/kernel-janitors
Quoted 8 lines · Bernd Petrovitsch
Quoted 5 lines · nikhil mishra
hello concerned
while(1)fork();
why this code has a problem is quite understood .
what can be the solution ?"Don't do it." is the other solution.
But not the best. The best one is to find out which (presumably, Indian) Linux website typoed newbies as janitors.
_______________________________________________
Kernel-janitors mailing list
[email protected]
https://lists.osdl.org/mailman/listinfo/kernel-janitors