modified by ohneta
Fork of ESP8266 by
Diff: ESP8266.cpp
- Revision:
- 10:965fbbf4169d
- Parent:
- 8:80048194de79
- Child:
- 11:1ee70fa0fdea
--- a/ESP8266.cpp Thu Jul 23 21:25:06 2015 +0000 +++ b/ESP8266.cpp Fri Jul 24 22:43:06 2015 +0000 @@ -88,7 +88,7 @@ bool ESP8266::openSocket(string sockType, int id, int port, char* addr) { //IDs only 0-4 - if(id > 4) + if(id > 4 || id < 0) return false; char portstr[5]; @@ -133,7 +133,7 @@ bool ESP8266::close(int id) { //IDs only 0-4 - if(id > 4) + if(id > 4 || id < 0) return false; char idstr[2];