From 78fdb921cd4bea9cbf500ae7ff75f14a6cff5b73 Mon Sep 17 00:00:00 2001 From: Peter Kokot Date: Sun, 14 Jan 2024 23:07:59 +0100 Subject: [PATCH] Fix the SO_LISTENQLEN check in FPM This now defines the HAVE_LQ_SO_LISTENQ as the fallback check when all previous have failed in case of FPM LQ. This seemed to be a typo in the build system. --- sapi/fpm/config.m4 | 4 ++-- sapi/fpm/fpm/fpm_sockets.c | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/sapi/fpm/config.m4 b/sapi/fpm/config.m4 index 26ed211a24230..a2aa53b2d3d66 100644 --- a/sapi/fpm/config.m4 +++ b/sapi/fpm/config.m4 @@ -343,8 +343,8 @@ AC_DEFUN([AC_FPM_LQ], AC_MSG_RESULT([no]) ]) - if test "$have_lq" = "tcp_info"; then - AC_DEFINE([HAVE_LQ_SO_LISTENQ], 1, [do we have SO_LISTENQxxx?]) + if test "$have_lq" = "so_listenq"; then + AC_DEFINE([HAVE_LQ_SO_LISTENQ], 1, [do we have SO_LISTENQ?]) fi fi ]) diff --git a/sapi/fpm/fpm/fpm_sockets.c b/sapi/fpm/fpm/fpm_sockets.c index 26be0a7fa2ce1..adff05983b130 100644 --- a/sapi/fpm/fpm/fpm_sockets.c +++ b/sapi/fpm/fpm/fpm_sockets.c @@ -609,9 +609,8 @@ int fpm_socket_get_listening_queue(int sock, unsigned *cur_lq, unsigned *max_lq) return 0; } -#endif -#ifdef HAVE_LQ_SO_LISTENQ +#elif defined(HAVE_LQ_SO_LISTENQ) int fpm_socket_get_listening_queue(int sock, unsigned *cur_lq, unsigned *max_lq) {