diff options
author | Sunil Nimmagadda <sunil@cvs.openbsd.org> | 2016-01-19 11:13:03 +0000 |
---|---|---|
committer | Sunil Nimmagadda <sunil@cvs.openbsd.org> | 2016-01-19 11:13:03 +0000 |
commit | 87dc01c6aad217927cbcf4a725a10fbc816b3828 (patch) | |
tree | 5bbbbc55cae82622fa60f7dd7ffb7077965883ad /usr.bin/mg | |
parent | 21c20d44dc6a423b7278e6fb9488e9f17cea7889 (diff) |
Skip empty entries in $PATH instead of erroneously interpreting
them as ".".
Ok lum@ jasper@
Diffstat (limited to 'usr.bin/mg')
-rw-r--r-- | usr.bin/mg/cscope.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/mg/cscope.c b/usr.bin/mg/cscope.c index 3a28835744e..1fa0efa4b5e 100644 --- a/usr.bin/mg/cscope.c +++ b/usr.bin/mg/cscope.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cscope.c,v 1.11 2015/09/29 02:07:49 guenther Exp $ */ +/* $OpenBSD: cscope.c,v 1.12 2016/01/19 11:13:02 sunil Exp $ */ /* * This file is in the public domain. @@ -612,7 +612,7 @@ csexists(const char *cmd) cmdlen = strlen(cmd); while ((dir = strsep(&path, ":")) != NULL) { if (*dir == '\0') - *dir = '.'; + continue; dlen = strlen(dir); while (dir[dlen-1] == '/') |