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.
Fork of SW_HTTPServer by
Diff: SW_HTTPServer.cpp
- Revision:
- 4:f34642902056
- Parent:
- 3:17928786bdb5
- Child:
- 5:c9b27e718054
diff -r 17928786bdb5 -r f34642902056 SW_HTTPServer.cpp --- a/SW_HTTPServer.cpp Mon Jun 24 20:02:01 2013 +0000 +++ b/SW_HTTPServer.cpp Tue Jun 25 16:37:06 2013 +0000 @@ -312,16 +312,16 @@ } -void HTTPServer::GetRemoteAddr(char * str, int size) +void HTTPServer::GetRemoteAddr(char * str, int strSize) { bool res = false; char *p; - if (size < 16) { // Can only guard it here w/o modifying Wifly class + if (strSize < 16) { // Can only guard it here w/o modifying Wifly class *str = '\0'; return; } - res = wifly->sendCommand("show z\r", "NO", str, 500); + res = wifly->sendCommand("show z\r", "NO", str, strSize, 500); wait(0.2); // how long to wait is fragile, but need the rest of the chars to come in... if (res) { p = strchr(str, '\n'); // truncate after the octets. @@ -644,3 +644,4 @@ memset(&perfData, 0, sizeof(perfData)); } +