what is the difference between fork() & exec()

Answer Posted / nitin

fork() creates a child process with most of the attributes
of the parent process. Both parent and child processes are
executed simultaneously.
exec() replaces the current process with a the executable
pointed by the function. Control never returns to the
original program unless there is an exec() error.

Is This Answer Correct ?    89 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of SOCK_STREAM Socket Type?

1031


What is the use getservent(3)?

1148


What does socket consist of?

464


How to Understand Network Byte Order?

1030


How to Generate Addresses?

980






How does socket communication work?

494


How to Specify an X.25 Address?

1003


How to Obtaine the Socket Address?

1024


What is socket connection?

490


How TCP/IP Handles Sequencing?

1155


What are Anonymous Calls?

995


What is the use of inet_addr() Function?

988


What is the use of PF_INET and SOCK_DGRAM?

1074


What is the Use of the inet_netof() Function?

910


What are Nameless Sockets?

1054