Merge pull request #7740 from mirelachirica/missing_resp_stop

Cellular: Handle AT response stop in case IP address is missing from …
pull/7742/merge
Cruz Monrreal 2018-08-16 09:06:05 -05:00 committed by GitHub
commit 7b8a13791b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -61,6 +61,7 @@ const char *AT_CellularStack::get_ip_address()
int len = _at.read_string(_ip, NSAPI_IPv4_SIZE - 1);
if (len == -1) {
_ip[0] = '\0';
_at.resp_stop();
_at.unlock();
// no IPV4 address, return
return NULL;