Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Download
Standard view
Full view
of .
Save to My Library
Look up keyword
Like this
0Activity
0 of .
Results for:
No results containing your search query
P. 1
Client Stringcs

Client Stringcs

Ratings: (0)|Views: 0 |Likes:
Published by Nivi Senthil
css123
css123

More info:

Published by: Nivi Senthil on Sep 23, 2013
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as DOCX, PDF, TXT or read online from Scribd
See more
See less

09/23/2013

pdf

text

original

 
#include<sys/types.h>#include<sys/socket.h>#include<netinet/in.h>#include<stdio.h>#include<string.h>int main(int argc,char **argv){sockfd=socket(AF_INET,SOCK_DGRAM,0);if(sockfd < 0)perror("\nsocket error\n");bzero(&servaddr,sizeof(servaddr));gets(str2);len=sizeof(servaddr);(sockfd < 0)perror("\nsocket error\n");bzero(&servaddr,sizeof(servaddr));gets(str2);len=sizeof(servaddr);sendto(sockfd,str2,sizeof(str2),0,(struct sockaddr*)&servaddr,len);recvfrom(sockfd,buff,sizeof(buff),0,(struct sockaddr*)&servaddr,&len);printf("\nThe message echoed : %s\n\n",buff);close(sockfd);return 0;}

You're Reading a Free Preview

Download
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->