From: Yann Ylavic Date: Thu, 23 Sep 2021 07:47:30 +0000 (+0000) Subject: mod_rewrite: Follow up to r1893519: Handle potential "unix://[authority]/". X-Git-Tag: 2.5.0-alpha2-ci-test-only~790 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=0557043c024429cef7a43862cd6b2724a75b39b9;p=thirdparty%2Fapache%2Fhttpd.git mod_rewrite: Follow up to r1893519: Handle potential "unix://[authority]/". is_absolute_uri() should return the offset to the authority part, if any. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1893532 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/mappers/mod_rewrite.c b/modules/mappers/mod_rewrite.c index dc21a8eb83b..343b700c75c 100644 --- a/modules/mappers/mod_rewrite.c +++ b/modules/mappers/mod_rewrite.c @@ -658,7 +658,7 @@ static unsigned is_absolute_uri(char *uri, int *supportsqs) case 'U': if (!ap_cstr_casecmpn(uri, "nix:", 4)) { /* unix: */ *sqs = 1; - return 5; + return (uri[4] == '/' && uri[5] == '/') ? 7 : 5; } }