aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mm-broadband-bearer.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mm-broadband-bearer.c b/src/mm-broadband-bearer.c
index 508da561..a63b08ff 100644
--- a/src/mm-broadband-bearer.c
+++ b/src/mm-broadband-bearer.c
@@ -857,7 +857,8 @@ parse_pdp_list (MMBaseModem *self,
mm_dbg ("Found PDP context with CID %u and no APN",
pdp->cid);
cid = pdp->cid;
- } else if (g_str_equal (pdp->apn, ctx->self->priv->apn)) {
+ } else if (ctx->self->priv->apn &&
+ g_str_equal (pdp->apn, ctx->self->priv->apn)) {
/* Found a PDP context with the same CID, we'll use it. */
mm_dbg ("Found PDP context with CID %u for APN '%s'",
pdp->cid, pdp->apn);