summaryrefslogtreecommitdiff
path: root/string.c
diff options
context:
space:
mode:
Diffstat (limited to 'string.c')
-rw-r--r--string.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/string.c b/string.c
index a871b68..0a92cca 100644
--- a/string.c
+++ b/string.c
@@ -75,3 +75,13 @@ safestrcpy(char *s, const char *t, int n)
return os;
}
+int
+strlen(const char *s)
+{
+ int n;
+
+ for(n = 0; s[n]; n++)
+ ;
+ return n;
+}
+