diff options
| author | Ruslan Ermilov <ru@FreeBSD.org> | 2010-01-06 08:26:43 +0000 |
|---|---|---|
| committer | Ruslan Ermilov <ru@FreeBSD.org> | 2010-01-06 08:26:43 +0000 |
| commit | c7fabb717622b35a5643cdecba354eb1c7a8c0fd (patch) | |
| tree | 6ba40b3fb38797822c568411eaeff30cf479999d /usr.bin | |
| parent | 64af44893a07704b8cf55e9afa856b18d7a445c4 (diff) | |
Notes
Diffstat (limited to 'usr.bin')
| -rw-r--r-- | usr.bin/fetch/fetch.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/usr.bin/fetch/fetch.c b/usr.bin/fetch/fetch.c index 2512a2e8632c..7553bd8d1028 100644 --- a/usr.bin/fetch/fetch.c +++ b/usr.bin/fetch/fetch.c @@ -340,6 +340,11 @@ fetch(char *URL, const char *path) fetchDebug = 1; /* parse URL */ + url = NULL; + if (*URL == '\0') { + warnx("empty URL"); + goto failure; + } if ((url = fetchParseURL(URL)) == NULL) { warnx("%s: parse error", URL); goto failure; |
