gprs: avoid useless loop iteration

This commit is contained in:
Rémi Denis-Courmont 2011-01-10 15:15:16 +02:00 committed by Marcel Holtmann
parent 08a8c06963
commit 6082339040
1 changed files with 3 additions and 3 deletions

View File

@ -1993,12 +1993,12 @@ void ofono_gprs_context_deactivated(struct ofono_gprs_context *gc,
for (l = gc->gprs->contexts; l; l = l->next) {
ctx = l->data;
if (ctx->active == FALSE)
continue;
if (ctx->context.cid != cid)
continue;
if (ctx->active == FALSE)
break;
gprs_cid_release(ctx->gprs, ctx->context.cid);
ctx->context.cid = 0;
ctx->active = FALSE;