Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

urlapi: skip path checks if path is just "/" #10385

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 3 additions & 2 deletions lib/urlapi.c
Expand Up @@ -1200,9 +1200,10 @@ static CURLUcode parseurl(const char *url, CURLU *u, unsigned int flags)
path = u->path = Curl_dyn_ptr(&enc);
}

if(!pathlen) {
/* there is no path left, unset */
if(pathlen <= 1) {
/* there is no path left or just the slash, unset */
path = NULL;
pathlen = 0;
bagder marked this conversation as resolved.
Show resolved Hide resolved
}
else {
if(!u->path) {
Expand Down