mirror of git://git.sysmocom.de/ofono
mbmmodem: remove NULL check
This commit is contained in:
parent
52e46e42ff
commit
3fbf85ed82
|
@ -364,9 +364,6 @@ static void mbm_gprs_activate_primary(struct ofono_gprs_context *gc,
|
|||
|
||||
DBG("cid %u", ctx->cid);
|
||||
|
||||
if (cbd == NULL)
|
||||
goto error;
|
||||
|
||||
gcd->active_context = ctx->cid;
|
||||
|
||||
cbd->user = gc;
|
||||
|
@ -408,16 +405,12 @@ static void mbm_gprs_deactivate_primary(struct ofono_gprs_context *gc,
|
|||
|
||||
DBG("cid %u", cid);
|
||||
|
||||
if (cbd == NULL)
|
||||
goto error;
|
||||
|
||||
cbd->user = gc;
|
||||
|
||||
if (g_at_chat_send(gcd->chat, "AT*ENAP=0", none_prefix,
|
||||
at_enap_down_cb, cbd, g_free) > 0)
|
||||
return;
|
||||
|
||||
error:
|
||||
g_free(cbd);
|
||||
|
||||
CALLBACK_WITH_FAILURE(cb, data);
|
||||
|
|
|
@ -88,7 +88,7 @@ static void mbm_stk_envelope(struct ofono_stk *stk, int length,
|
|||
|
||||
DBG("");
|
||||
|
||||
if (cbd == NULL || buf == NULL)
|
||||
if (buf == NULL)
|
||||
goto error;
|
||||
|
||||
len = sprintf(buf, "AT*STKE=\"");
|
||||
|
@ -134,7 +134,7 @@ static void mbm_stk_terminal_response(struct ofono_stk *stk, int length,
|
|||
|
||||
DBG("");
|
||||
|
||||
if (cbd == NULL || buf == NULL)
|
||||
if (buf == NULL)
|
||||
goto error;
|
||||
|
||||
len = sprintf(buf, "AT*STKR=\"");
|
||||
|
|
Loading…
Reference in New Issue