summaryrefslogtreecommitdiffhomepage
path: root/dev/kernel/src
diff options
context:
space:
mode:
Diffstat (limited to 'dev/kernel/src')
-rw-r--r--dev/kernel/src/FS/HeFS+FileSystemParser.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/dev/kernel/src/FS/HeFS+FileSystemParser.cc b/dev/kernel/src/FS/HeFS+FileSystemParser.cc
index 8092f53b..344369d5 100644
--- a/dev/kernel/src/FS/HeFS+FileSystemParser.cc
+++ b/dev/kernel/src/FS/HeFS+FileSystemParser.cc
@@ -89,6 +89,8 @@ namespace Detail {
/// @param path the directory path.
/// @return The hashed path.
STATIC UInt64 hefsi_hash_64(const Utf8Char* path) {
+ if (!path || *path == 0) return 0;
+
const UInt64 FNV_OFFSET_BASIS = 0xcbf29ce484222325ULL;
const UInt64 FNV_PRIME = 0x100000001b3ULL;