NetworkSocketAPI
Dependents: HelloWizFi250Interface
Fork of NetworkSocketAPI by
Revision 108:2e5eccf30a84, committed 2016-04-20
- Comitter:
- geky
- Date:
- Wed Apr 20 00:46:23 2016 +0000
- Parent:
- 107:8b26e40c6e34
- Child:
- 109:5d8bd5752386
- Commit message:
- Fixe race condition in socket close
Changed in this revision
Socket.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/Socket.cpp Tue Apr 19 18:34:42 2016 -0500 +++ b/Socket.cpp Wed Apr 20 00:46:23 2016 +0000 @@ -52,8 +52,10 @@ if (!_socket) { return 0; } - - void *socket = _socket; + + _iface->socket_attach(_socket, 0, 0); + + void *volatile socket = _socket; _socket = 0; return _iface->socket_close(socket); }