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.
Dependencies: ATParser
Fork of ESP8266 by
Revision 10:965fbbf4169d, committed 2015-07-24
- Comitter:
- sarahmarshy
- Date:
- Fri Jul 24 22:43:06 2015 +0000
- Parent:
- 8:80048194de79
- Child:
- 11:1ee70fa0fdea
- Commit message:
- Revisions
Changed in this revision
| ESP8266.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- 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];
