summaryrefslogtreecommitdiff
path: root/src/unix.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/unix.cpp')
-rw-r--r--src/unix.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/unix.cpp b/src/unix.cpp
index 72ac0db12..43429778d 100644
--- a/src/unix.cpp
+++ b/src/unix.cpp
@@ -53,7 +53,7 @@ bool FiosIsRoot(const char *path)
#else
/* On MorphOS or AmigaOS paths look like: "Volume:directory/subdirectory" */
const char *s = strchr(path, ':');
- return s[1] == '\0';
+ return s != NULL && s[1] == '\0';
#endif
}