]> granicus.if.org Git - apache/commitdiff
Good grief! How hard is it to try _all_ the elements in a list?
authorBen Laurie <ben@apache.org>
Sun, 25 Jul 1999 13:58:58 +0000 (13:58 +0000)
committerBen Laurie <ben@apache.org>
Sun, 25 Jul 1999 13:58:58 +0000 (13:58 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@83502 13f79535-47bb-0310-9956-ffa450edef68

server/mpm/prefork/prefork.c

index 717736caaea5675f9a218ee686ee4ce30e483217..dfc68b0df615de7e2e9c8c9a33a81b3b0e415ca1 100644 (file)
@@ -2061,6 +2061,7 @@ static void child_main(int child_num_arg)
     struct sockaddr sa_client;
     ap_listen_rec *lr;
     ap_listen_rec *last_lr;
+    ap_listen_rec *first_lr;
     pool *ptrans;
     conn_rec *current_conn;
     ap_iol *iol;
@@ -2160,7 +2161,8 @@ static void child_main(int child_num_arg)
                else {
                    lr = last_lr->next;
                }
-               while (lr != last_lr) {
+               first_lr=lr;
+               do {
                    if (!lr) {
                        lr = ap_listeners;
                    }
@@ -2168,6 +2170,7 @@ static void child_main(int child_num_arg)
                        goto got_listener;
                    lr = lr->next;
                }
+               while (lr != first_lr);
                continue;
        got_listener:
                last_lr = lr;