Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Diff: TCPServer.cpp
- Revision:
- 21:65a9f84862f0
- Parent:
- 20:dd5f19874adf
- Child:
- 24:656011e49d9f
--- a/TCPServer.cpp	Tue Apr 19 18:23:29 2016 -0500
+++ b/TCPServer.cpp	Tue Apr 19 18:23:42 2016 -0500
@@ -64,9 +64,8 @@
         }
 
         void *socket;
-        int err = _iface->socket_accept(_socket, &socket);
-
-        if (err > 0) {
+        int err = _iface->socket_accept(&socket, _socket);
+        if (!err) {
             connection->_socket = socket;
         }