aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/tool_urlglob.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tool_urlglob.c b/src/tool_urlglob.c
index 1644077f2..7c7bd4b35 100644
--- a/src/tool_urlglob.c
+++ b/src/tool_urlglob.c
@@ -287,7 +287,7 @@ static GlobCode glob_range(URLGlob *glob, char **patternp,
}
else
step_n = 1;
- if(*endp == ']') {
+ if(endp && (*endp == ']')) {
pattern= endp+1;
}
else