]> git.kaiwu.me - haproxy.git/commitdiff
BUG/MINOR: cfgcond: make KQUEUE check for GTUNE_USE_KQUEUE not GTUNE_USE_EPOLL
authorWilly Tarreau <w@1wt.eu>
Mon, 11 May 2026 13:27:51 +0000 (15:27 +0200)
committerWilly Tarreau <w@1wt.eu>
Mon, 11 May 2026 14:04:19 +0000 (16:04 +0200)
In cfg_eval_cond_enabled(), the "KQUEUE" option incorrectly checks
GTUNE_USE_EPOLL instead of GTUNE_USE_KQUEUE. This is a copy-paste bug
from the preceding EPOLL case. It can be backported though it's harmless.

src/cfgcond.c

index 58659a49ffaab038b12653794d84cef813fae6ce..f012e6040b02242fe79a9b3d25d47005a7af9e61 100644 (file)
@@ -190,7 +190,7 @@ static int cfg_eval_cond_enabled(const char *str)
        else if (strcmp(str, "EPOLL") == 0)
                return !!(global.tune.options & GTUNE_USE_EPOLL);
        else if (strcmp(str, "KQUEUE") == 0)
-               return !!(global.tune.options & GTUNE_USE_EPOLL);
+               return !!(global.tune.options & GTUNE_USE_KQUEUE);
        else if (strcmp(str, "EVPORTS") == 0)
                return !!(global.tune.options & GTUNE_USE_EVPORTS);
        else if (strcmp(str, "SPLICE") == 0)