]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Add a 'strvalid()' call to libkern. Given a character pointer, and
authorrwatson <rwatson@FreeBSD.org>
Mon, 18 Feb 2002 00:37:03 +0000 (00:37 +0000)
committerrwatson <rwatson@FreeBSD.org>
Mon, 18 Feb 2002 00:37:03 +0000 (00:37 +0000)
commit49c65a6b10085c64f7ff4dfb8ccc792f1e9dbc75
treeca54ff259a2aa28bbc146e5a0c0d691cd98ede9f
parent43f97fe4ae07b305a42ebbd3f668b9fdeecbaa5f
Add a 'strvalid()' call to libkern.  Given a character pointer, and
buffer length, determine if the pointer is to a valid string.  Currently,
the only check is whether a '\0' appears in the buffer.  This is useful
when pulling in a structure from userland that may contain one or more
strings, and validity testing must be performed on elements of the
structure.  When copying normal string arguments, copyinstr() is
expected to be used.
sys/conf/files
sys/libkern/strvalid.c [new file with mode: 0644]
sys/sys/libkern.h