Hiroshi Yamaguchi / Mbed 2 deprecated SimpleSocketExamples 1.0

Dependencies:   EthernetNetIf SimpleSocket 1.0 mbed

Revision:
11:04c0acd7f510
Parent:
10:62ce72ee3e91
Child:
12:52170a866d4a
--- a/Example/echoserver.cpp	Thu Aug 18 08:46:47 2011 +0000
+++ b/Example/echoserver.cpp	Thu Aug 18 09:51:08 2011 +0000
@@ -12,12 +12,12 @@
     timer.start();
 
     while (true) {
-        if (ClientSocket *socket = server.accept()) {
-            while (socket->connected()) {
+        if (ClientSocket *clientSocket = server.accept()) {
+            while (clientSocket->connected()) {
                 char buf[8];
-                int len = socket->read(buf, sizeof(buf));
+                int len = clientSocket->read(buf, sizeof(buf));
                 if (len > 0)
-                    socket->write(buf, len);
+                    clientSocket->write(buf, len);
 
                 if (timer.read() > 10) {
                     timer.reset();