[nginx] Fix valgrind errors in mail tests

Robert Mueller robm at fastmailteam.com
Mon May 13 05:43:58 UTC 2024


# HG changeset patch
# User Rob Mueller <robm at fastmailteam.com>
Fix valgrind errors in mail tests

Applying this fix allows nginx to be run under valgrind and all
mail_* tests to pass with no valgrand issues detected
---
 src/event/modules/ngx_epoll_module.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/event/modules/ngx_epoll_module.c b/src/event/modules/ngx_epoll_module.c
index 98e3ce7c8..c89a56d95 100644
--- a/src/event/modules/ngx_epoll_module.c
+++ b/src/event/modules/ngx_epoll_module.c
@@ -474,6 +474,7 @@ ngx_epoll_test_rdhup(ngx_cycle_t *cycle)
     }
 
     ee.events = EPOLLET|EPOLLIN|EPOLLRDHUP;
+    ee.data.u64 = 0;
 
     if (epoll_ctl(ep, EPOLL_CTL_ADD, s[0], &ee) == -1) {
         ngx_log_error(NGX_LOG_ALERT, cycle->log, ngx_errno,




More information about the nginx-devel mailing list