Skip to content

Commit

Permalink
Minor fix for odd PATH entries.
Browse files Browse the repository at this point in the history
  • Loading branch information
icculus committed Nov 30, 2002
1 parent 9d82110 commit c79285a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion platform/unix.c
Expand Up @@ -221,7 +221,7 @@ static char *findBinaryInPath(const char *bin, char *envr)

/* build full binary path... */
strcpy(exe, start);
if (exe[strlen(exe) - 1] != '/')
if ((exe[0] == '\0') || (exe[strlen(exe) - 1] != '/'))
strcat(exe, "/");
strcat(exe, bin);

Expand Down

0 comments on commit c79285a

Please sign in to comment.