summaryrefslogtreecommitdiff
path: root/dir.c
diff options
context:
space:
mode:
Diffstat (limited to 'dir.c')
-rw-r--r--dir.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/dir.c b/dir.c
index 5386ff03f2..5190ea4e9e 100644
--- a/dir.c
+++ b/dir.c
@@ -1690,7 +1690,7 @@ ruby_glob0(const char *path, int flags, ruby_glob_func *func, VALUE arg, rb_enco
root = rb_enc_path_skip_prefix(root, root + strlen(root), enc);
#endif
- if (root && *root == '/') root++;
+ if (*root == '/') root++;
n = root - start;
buf = GLOB_ALLOC_N(char, n + 1);