vfork()

Ralf U. Holighaus ralfi at pemcom.pem-stuttgart.de
Fri Mar 22 19:02:42 AEST 1991


gwyn at smoke.brl.mil (Doug Gwyn) writes:

>In article <8372 at rsiatl.Dixie.Com> stan at Dixie.Com (Stan Brown) writes:
>>	Could someone tell me how this is different from fork()

>Just replace it with fork().  If that doesn't work, the application
>is going to need some serious redesign anyway.

That is PARTLY right. vfork differs from fork in a way that it doesn't
copy the complete process data range, so the child of a vfork can ONLY
do an exec, execlp etc. 

Actually with vfork, the sun process shares text and data with the father
process, so the only thing possible after a vfork is either an exit by
the father or an exec by the son. Any other use will cause garbage, be-
cause neither of the two processes has a data rang for it's own.

Regards 

Ralf.
-- 
  PEM Programmentwicklungsgesellschaft    |         Ralf U. Holighaus
        fuer Microcomputer mbH            |         Technical Support
PO-Box 810165 D-7000 Stuttgart 80 Germany | holighaus at pemstgt.PEM-Stuttgart.de
VOICE: x49-711-713045 FAX: x49-711-713047 |       ..!unido!pemcom!ralfi 



More information about the Comp.unix.questions mailing list