Another Echo Server
Dependencies: EthernetNetIf mbed
Revision 1:da09e6a94937, committed 2010-09-06
- Comitter:
- xshige
- Date:
- Mon Sep 06 15:22:33 2010 +0000
- Parent:
- 0:c3fbb0514bfc
- Commit message:
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r c3fbb0514bfc -r da09e6a94937 main.cpp --- a/main.cpp Sun Sep 05 15:42:09 2010 +0000 +++ b/main.cpp Mon Sep 06 15:22:33 2010 +0000 @@ -1,6 +1,6 @@ // TCP Echo server -// 2010/9/6 +// 2010/9/7 /* @@ -67,7 +67,7 @@ while ( int len = pConnectedSock->recv(buff, 128) ) { // And send straight back out again pConnectedSock->send(buff, len); - buff[len+1]=0; // make terminater + buff[len]=0; // make terminater printf("Received&Wrote:%s\r\n",buff); } break;