]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-http: test_run_client_server() - Rearrange the reset/wait calls that sync test_ru...
authorMarco Bettini <marco.bettini@open-xchange.com>
Wed, 18 Jan 2023 16:59:29 +0000 (16:59 +0000)
committerMarco Bettini <marco.bettini@open-xchange.com>
Thu, 19 Jan 2023 14:11:57 +0000 (14:11 +0000)
src/lib-http/test-http-client-errors.c

index 631a40ae76ca8d7261fa338b609b9770de4ea6be..7b1e29fa73d99b37423012fa0ab18fb20e192788 100644 (file)
@@ -3847,7 +3847,6 @@ test_run_client_server(const struct http_client_settings *client_set,
 {
        unsigned int i;
 
-       test_subprocess_notify_signal_reset(SIGHUP);
        test_server_init = NULL;
        test_server_deinit = NULL;
        test_server_input = NULL;
@@ -3868,10 +3867,10 @@ test_run_client_server(const struct http_client_settings *client_set,
 
                        /* Fork server */
                        fd_listen = fds[i];
+                       test_subprocess_notify_signal_reset(SIGHUP);
                        test_subprocess_fork(test_run_server, &data, FALSE);
-                       i_close_fd(&fd_listen);
                        test_subprocess_notify_signal_wait(SIGHUP, 10000);
-                       test_subprocess_notify_signal_reset(SIGHUP);
+                       i_close_fd(&fd_listen);
                }
        }