From ae0af0d011fe1231b7c46f671bec0ebf92af084d Mon Sep 17 00:00:00 2001 From: des Date: Wed, 13 Dec 2000 11:21:09 +0000 Subject: Avoid a segfault (due to an unitialized pointer) when parsing URLs that have no scheme or host part. --- lib/libfetch/fetch.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/libfetch/fetch.c') diff --git a/lib/libfetch/fetch.c b/lib/libfetch/fetch.c index b26cad0..bc803d5 100644 --- a/lib/libfetch/fetch.c +++ b/lib/libfetch/fetch.c @@ -314,6 +314,8 @@ fetchParseURL(char *URL) */ if (URL[1] == '/') URL = (p += 2); + } else { + p = URL; } if (!*URL || *URL == '/') goto nohost; -- cgit v1.1