Re: lug-bg: fork, programirane
- Subject: Re: lug-bg: fork, programirane
- From: victor.bg@xxxxxxxxxxxx (victor.bg@xxxxxxxxxxxx)
- Date: Thu, 04 May 2000 22:34:51 +0300
Dimo Dimitrov-DataManagement wrote:
> if (!fork())
>
> /*Child process*/
> if (send (new_fd, "Hello, world! \n" , 14, 0) == -1 )
> perror ("send");
> exit(0);
> }
> else
> {
> /* Parent process. Wait for the child to complette */
> waitpid(-1, NULL, 0);
> close(new_fd);
> }
10x -- tova closeva conection otkum clienta. Servera obace ne se closeva.
Kakto i da e. Ako na niakoi mu e interesno namerih tutorial na
www.cs.cf.ac.uk/Dave/C/CE.html
predpolagam, ce moze da se drupne s wget.
Victor Senderov
==================================================================
A mail-list of Linux Users Group - Bulgaria (bulgarian linuxers)
Otpiswaneto RABOTI !!! : Majordomo@xxxxxxxxxxxxxxxxxx UNSUBSCRIBE LUG-BG
http://www.linux-bulgaria.org/ Hosted by Internet Group Ltd. - Stara Zagora
|