summaryrefslogtreecommitdiff
path: root/src/regress/lib/libc/stpncpy
diff options
context:
space:
mode:
authorcvs2svn <admin@example.com>2012-07-13 17:49:56 +0000
committercvs2svn <admin@example.com>2012-07-13 17:49:56 +0000
commit6f82d0e8f9756938f04071892206a5af85e676f0 (patch)
tree821921a1dd0a5a3cece91121e121cc63c4b68128 /src/regress/lib/libc/stpncpy
parent9204e59073bcf27e1487ec4ac46e981902ddd904 (diff)
downloadopenbsd-eric_g2k12.tar.gz
openbsd-eric_g2k12.tar.bz2
openbsd-eric_g2k12.zip
This commit was manufactured by cvs2git to create tag 'eric_g2k12'.eric_g2k12
Diffstat (limited to 'src/regress/lib/libc/stpncpy')
-rw-r--r--src/regress/lib/libc/stpncpy/Makefile3
-rw-r--r--src/regress/lib/libc/stpncpy/stpncpy_test.c24
2 files changed, 0 insertions, 27 deletions
diff --git a/src/regress/lib/libc/stpncpy/Makefile b/src/regress/lib/libc/stpncpy/Makefile
deleted file mode 100644
index 9333934da6..0000000000
--- a/src/regress/lib/libc/stpncpy/Makefile
+++ /dev/null
@@ -1,3 +0,0 @@
1PROG=stpncpy_test
2
3.include <bsd.regress.mk>
diff --git a/src/regress/lib/libc/stpncpy/stpncpy_test.c b/src/regress/lib/libc/stpncpy/stpncpy_test.c
deleted file mode 100644
index 63b7d25e53..0000000000
--- a/src/regress/lib/libc/stpncpy/stpncpy_test.c
+++ /dev/null
@@ -1,24 +0,0 @@
1/* $OpenBSD: stpncpy_test.c,v 1.1 2012/07/11 10:46:23 naddy Exp $ */
2
3/*
4 * Public domain, 2012, Christian Weisgerber <naddy@openbsd.org>
5 */
6
7#include <string.h>
8
9int main(void)
10{
11 char dst[8];
12 char *src = "abcdef";
13
14 if (stpncpy(dst, src, 5) != dst + 5)
15 return 1;
16 if (stpncpy(dst, src, 6) != dst + 6)
17 return 1;
18 if (stpncpy(dst, src, 7) != dst + 6)
19 return 1;
20 if (stpncpy(dst, src, 8) != dst + 6)
21 return 1;
22
23 return 0;
24}