]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-http: test-http-client-errors - Add synchronization for test_run_dns() startup
authorMarco Bettini <marco.bettini@open-xchange.com>
Wed, 18 Jan 2023 17:06:50 +0000 (17:06 +0000)
committerMarco Bettini <marco.bettini@open-xchange.com>
Thu, 19 Jan 2023 14:12:40 +0000 (14:12 +0000)
src/lib-http/test-http-client-errors.c

index 7b1e29fa73d99b37423012fa0ab18fb20e192788..ed42326dea61a88ff502d1c2154b8990a1ed5491 100644 (file)
@@ -3808,6 +3808,7 @@ static int test_run_dns(test_dns_init_t dns_test)
        if (debug)
                i_debug("PID=%s", my_pid);
 
+       test_subprocess_notify_signal_send_parent(SIGHUP);
        ioloop = io_loop_create();
        dns_test();
        io_loop_destroy(&ioloop);
@@ -3885,7 +3886,9 @@ test_run_client_server(const struct http_client_settings *client_set,
 
                /* Fork DNS service */
                fd_listen = fd;
+               test_subprocess_notify_signal_reset(SIGHUP);
                test_subprocess_fork(test_run_dns, dns_test, FALSE);
+               test_subprocess_notify_signal_wait(SIGHUP, 10000);
                i_close_fd(&fd_listen);
        }