From: Marko Kreen Date: Sat, 4 Aug 2007 21:29:24 +0000 (+0000) Subject: use goto instead break because of 2 loops X-Git-Tag: pgbouncer_1_1~61 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7dd760dcac33ddd1bcdbf7f214f53631a944be46;p=pgbouncer use goto instead break because of 2 loops --- diff --git a/src/objects.c b/src/objects.c index 8f30751..d9ccad8 100644 --- a/src/objects.c +++ b/src/objects.c @@ -867,10 +867,11 @@ void accept_cancel_request(PgSocket *req) client = container_of(citem, PgSocket, head); if (memcmp(client->cancel_key, req->cancel_key, 8) == 0) { main_client = client; - break; + goto found; } } } +found: /* wrong key */ if (!main_client) {