summaryrefslogtreecommitdiffhomepage
path: root/dev/kernel/src/FS/HeFS+FileSystemParser.cc
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@nekernel.org>2025-09-04 11:54:55 +0200
committerGitHub <noreply@github.com>2025-09-04 11:54:55 +0200
commit0f88e96c0cf7ffaccecae94794024164c510f735 (patch)
tree66ebc7e2cb99a0e54ca7b2da4b617ceed6e98a3d /dev/kernel/src/FS/HeFS+FileSystemParser.cc
parentaead694f3cada63e4dc2d79653a5b0efe0d9f49f (diff)
parent77dc0a650819b460480e1c0be5409fc322a6d2a4 (diff)
Merge pull request #61 from nekernel-org/devv0.0.5
NeKernel: v0.0.5 (Arlington)
Diffstat (limited to 'dev/kernel/src/FS/HeFS+FileSystemParser.cc')
-rw-r--r--dev/kernel/src/FS/HeFS+FileSystemParser.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/dev/kernel/src/FS/HeFS+FileSystemParser.cc b/dev/kernel/src/FS/HeFS+FileSystemParser.cc
index f1531b4c..86f929c0 100644
--- a/dev/kernel/src/FS/HeFS+FileSystemParser.cc
+++ b/dev/kernel/src/FS/HeFS+FileSystemParser.cc
@@ -88,7 +88,8 @@ namespace Detail {
/// @brief Simple algorithm to hash directory entries for INDs.
/// @param path the directory path.
/// @return The hashed path.
- STATIC UInt64 hefsi_hash_64(const Utf8Char* path) {
+ template <typename CharT = Utf8Char>
+ STATIC UInt64 hefsi_hash_64(const CharT* path) {
if (!path || *path == 0) return 0;
const UInt64 kFnvBaseOffset = 0xcbf29ce484222325ULL;
@@ -97,7 +98,7 @@ namespace Detail {
UInt64 hash = kFnvBaseOffset;
while (*path) {
- hash ^= (Utf8Char) (*path++);
+ hash ^= (CharT) (*path++);
hash *= kFnvPrimeNumber;
}