Skip to content

Commit d55f6a9

Browse files
author
Marc Emmers
committed
Check if a queue is present. Return an error otherwise
1 parent 2de83fb commit d55f6a9

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

features/cellular/easy_cellular/CellularConnectionFSM.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,10 @@ nsapi_error_t CellularConnectionFSM::init()
136136
}
137137

138138
_at_queue = _cellularDevice->get_queue();
139+
if (!_at_queue) {
140+
stop();
141+
return NSAPI_ERROR_NO_MEMORY;
142+
}
139143
_at_queue->chain(&_queue);
140144

141145
_retry_count = 0;

0 commit comments

Comments
 (0)