summaryrefslogtreecommitdiffhomepage
path: root/include/string.h
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@nekernel.org>2025-12-28 09:30:38 +0100
committerAmlal El Mahrouss <amlal@nekernel.org>2025-12-28 09:30:38 +0100
commit7df7ed6d026c5e1f3b8111e3536af3771301c177 (patch)
treef87916ee645aec06971a84dc1e9e5f1267fbe755 /include/string.h
parent176cf8f237745d658185a2fba8fff1401c1c2b5f (diff)
feat! firmware breaking changes on the API.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'include/string.h')
-rw-r--r--include/string.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/include/string.h b/include/string.h
new file mode 100644
index 0000000..586e54a
--- /dev/null
+++ b/include/string.h
@@ -0,0 +1,22 @@
+// Copyright 2024-2025, Amlal El Mahrouss (amlal@nekernel.org)
+// Distributed under the Apache Software License, Version 2.0. (See accompanying
+// file LICENSE_1_0.txt or copy at http://www.apache.org/licenses/LICENSE-2.0)
+// Official repository: https://github.com/nekernel-org/neboot
+
+#pragma once
+
+#include <include/boot.h>
+
+#define strncpy(DST, SRC, LEN) memncpy(DST, SRC, LEN)
+
+void strreverse(char* in_out);
+size_t strlen(const char* in);
+size_t strnlen(const char* in, size_t maxLen);
+void* memset(void* dst, const char val, size_t len);
+size_t memcpy(void* dst, const void* src);
+size_t memncpy(void* dst, const void* src, size_t len);
+void* memmove(void* dst, const void* src, size_t len);
+size_t strncmp(const char* cmp1, const char* cmp2, size_t len);
+char* strchr(char* str, const char chr);
+
+#define zero_memory(dst, sz) memset(dst, 0, sz)