BarryServer : Git

All the code for all my projects
// BarryServer : Git / OrionLibC / commit / 03048a95d88cc7a78171393371f5c22a0250a014 / string / strlen.c

// Related

OrionLibC

Barry Importing existing Orion LibC 03048a9 (2 years, 2 months ago)
diff --git a/string/strlen.c b/string/strlen.c
new file mode 100644
index 0000000..a8d506c
--- /dev/null
+++ b/string/strlen.c
@@ -0,0 +1,12 @@
+#include <string.h>
+
+/* Find length of string */
+size_t
+strlen(const char *str)
+{
+	if (!str)
+		return 0;
+	size_t i;
+	for (i = 0; str[i]; i++);
+	return i;
+}