This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
about read(...) of TCP/IP
- To: "ecos-discuss" <ecos-discuss at sourceware dot cygnus dot com>
- Subject: [ECOS] about read(...) of TCP/IP
- From: "ylyuan" <ylyuan at davform dot com>
- Date: Wed, 28 Mar 2001 09:42:46 +0800
Hi,part of my program is:
if ((s = socket(AF_INET, SOCK_STREAM, 0)) < 0) {
printf("error to creat a socket\n");
exit(1);
}
if (connect(s, (struct sockaddr *)&sin, sizeof(sin)) < 0) {
printf("error to connect\n");
exit(1);
}
read(s,buf,sizeof(buf));
Because the destination connected is a pop3 server,the function of read should gain some information ,but it won't return.From the buffer of hardware,I can see the information that I want.Because the test of ppp_ping.c runs right,so I doubt the question exists in TCP.
Thanks a lot!