winhttp: Do not use countof() on pointer argument
authorTobias Brunner <tobias@strongswan.org>
Wed, 2 Jul 2014 10:08:16 +0000 (12:08 +0200)
committerTobias Brunner <tobias@strongswan.org>
Wed, 2 Jul 2014 10:38:45 +0000 (12:38 +0200)
src/libstrongswan/plugins/winhttp/winhttp_fetcher.c

index 6ab8662..5f0b584 100644 (file)
@@ -211,7 +211,7 @@ static bool parse_uri(private_winhttp_fetcher_t *this, char *uri,
        }
        if (comps.dwExtraInfoLength)
        {
-               wcsncat(path, extra, countof(path) - comps.dwUrlPathLength - 1);
+               wcsncat(path, extra, pathlen - comps.dwUrlPathLength - 1);
        }
        if (comps.nPort)
        {