From: Daniel Stenberg Date: Wed, 24 Jan 2024 12:15:18 +0000 (+0100) Subject: urlapi: remove assert X-Git-Tag: curl-8_6_0~45 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=162113676a894a1ec3ce463600571c4eb309b930;p=thirdparty%2Fcurl.git urlapi: remove assert This assert triggers wrongly when CURLU_GUESS_SCHEME and CURLU_NO_AUTHORITY are both set and the URL is a single path. I think this assert has played out its role. It was introduced in a rather big refactor. Follow-up to 4cfa5bcc9a Reported-by: promptfuzz_ on hackerone Closes #12775 --- diff --git a/lib/urlapi.c b/lib/urlapi.c index b9ea68eac5..3cd0362c51 100644 --- a/lib/urlapi.c +++ b/lib/urlapi.c @@ -1264,7 +1264,6 @@ static CURLUcode parseurl(const char *url, CURLU *u, unsigned int flags) pathlen -= fraglen; } - DEBUGASSERT(pathlen < urllen); query = memchr(path, '?', pathlen); if(query) { size_t qlen = fragment ? (size_t)(fragment - query) :