diff options
Diffstat (limited to 'newlib/libc/posix')
-rw-r--r-- | newlib/libc/posix/execvp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/newlib/libc/posix/execvp.c b/newlib/libc/posix/execvp.c index 6957f61b2..15b2e572c 100644 --- a/newlib/libc/posix/execvp.c +++ b/newlib/libc/posix/execvp.c @@ -73,7 +73,7 @@ _DEFUN (execvp, (file, argv), { strccpy (buf, path, PATH_DELIM); /* An empty entry means the current directory. */ - if (*buf != 0) + if (*buf != 0 && buf[strlen(buf) - 1] != '/') strcat (buf, "/"); strcat (buf, file); if (execv (buf, argv) == -1 && errno != ENOENT) |