In cellular api's _is_connected flag is private and is used in do_connect function and do_connectis virtual. How child classes can use this flag, _is_connected. when do_connectis overridden child classes.
Also when do_connect is overridden then we cannot set this flag, _is_connected. So while calling do_disconnect because of _is_connected this check become true and sets _cid = -1 and when deactivate_context function is called give error. It will be better to add some method to set _is_connected.
[ ] Question
[ ] Enhancement
[x] Bug
@wajahat-ublox @fahim-ublox
cc @ARMmbed/mbed-os-wan
Internal Jira reference: https://jira.arm.com/browse/MBOCUSTRIA-1854
@ARMmbed/mbed-os-maintainers , I think this issue can be closed. Fix has been merged a long time ago.
Most helpful comment
@ARMmbed/mbed-os-maintainers , I think this issue can be closed. Fix has been merged a long time ago.