]> git.kaiwu.me - haproxy.git/commitdiff
CLEANUP: h2: remove dead code around FND_AUTH in h2_prepare_htx_reqline()
authorWilly Tarreau <w@1wt.eu>
Thu, 3 Sep 2026 12:23:01 +0000 (14:23 +0200)
committerWilly Tarreau <w@1wt.eu>
Thu, 3 Sep 2026 14:25:08 +0000 (16:25 +0200)
In h2_prepare_htx_reqline(), we test (fields & H2_PHDR_FND_AUTH) in the
"else" branch of the same condition. Let's just drop it since it will
never match.

src/h2.c

index c66f79dca4aa0af85db883d2018b5762064938e9..5eefe9d8b72b1206bd3fc0e0cb47ae66d4e2db7e 100644 (file)
--- a/src/h2.c
+++ b/src/h2.c
@@ -252,8 +252,6 @@ static struct htx_sl *h2_prepare_htx_reqline(uint32_t fields, struct ist *phdr,
        else {
                /* usual schemes with or without authority, use origin form */
                uri = phdr[H2_PHDR_IDX_PATH];
-               if (fields & H2_PHDR_FND_AUTH)
-                       flags |= HTX_SL_F_HAS_AUTHORITY;
        }
 
        /* The method is a non-empty token (RFC7231#4.1) */