summaryrefslogtreecommitdiffstats
path: root/sys/lib/libkern/strnlen.c
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2014-06-10 04:16:57 +0000
committerderaadt <deraadt@openbsd.org>2014-06-10 04:16:57 +0000
commitb5be37d2a6fbef83b90ca99497343fa8dbb0f3fc (patch)
tree1cf108b2ad222066281b99f97279b11c93ece20d /sys/lib/libkern/strnlen.c
parentuse memset instead of bzero (diff)
downloadwireguard-openbsd-b5be37d2a6fbef83b90ca99497343fa8dbb0f3fc.tar.xz
wireguard-openbsd-b5be37d2a6fbef83b90ca99497343fa8dbb0f3fc.zip
mop up #ifdef _KERNEL goo; ok miod
Diffstat (limited to 'sys/lib/libkern/strnlen.c')
-rw-r--r--sys/lib/libkern/strnlen.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/sys/lib/libkern/strnlen.c b/sys/lib/libkern/strnlen.c
index ac439d066a2..92be016c055 100644
--- a/sys/lib/libkern/strnlen.c
+++ b/sys/lib/libkern/strnlen.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: strnlen.c,v 1.1 2012/04/26 01:22:31 matthew Exp $ */
+/* $OpenBSD: strnlen.c,v 1.2 2014/06/10 04:16:57 deraadt Exp $ */
/*
* Copyright (c) 2010 Todd C. Miller <Todd.Miller@courtesan.com>
@@ -17,12 +17,7 @@
*/
#include <sys/types.h>
-
-#if !defined(_KERNEL) && !defined(_STANDALONE)
-#include <string.h>
-#else
#include <lib/libkern/libkern.h>
-#endif
size_t
strnlen(const char *str, size_t maxlen)