Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libc/string due to an overwhelming rush of complaints, r...
details: https://anonhg.NetBSD.org/src/rev/1b79e0084d20
branches: trunk
changeset: 476262:1b79e0084d20
user: lukem <lukem%NetBSD.org@localhost>
date: Fri Sep 10 23:13:09 1999 +0000
description:
due to an overwhelming rush of complaints, remove the check for NULL
pointers. apparantly a lot of developers feel that potentially dumping
core is better than returning a status of `0 bytes copied'...
diffstat:
lib/libc/string/strlcat.c | 7 ++-----
lib/libc/string/strlcpy.c | 7 ++-----
2 files changed, 4 insertions(+), 10 deletions(-)
diffs (56 lines):
diff -r f7291f58749b -r 1b79e0084d20 lib/libc/string/strlcat.c
--- a/lib/libc/string/strlcat.c Fri Sep 10 22:49:33 1999 +0000
+++ b/lib/libc/string/strlcat.c Fri Sep 10 23:13:09 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: strlcat.c,v 1.2 1999/09/08 22:56:55 lukem Exp $ */
+/* $NetBSD: strlcat.c,v 1.3 1999/09/10 23:13:09 lukem Exp $ */
/* from OpenBSD: strlcat.c,v 1.2 1999/06/17 16:28:58 millert Exp */
/*
@@ -30,7 +30,7 @@
#include <sys/cdefs.h>
#if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: strlcat.c,v 1.2 1999/09/08 22:56:55 lukem Exp $");
+__RCSID("$NetBSD: strlcat.c,v 1.3 1999/09/10 23:13:09 lukem Exp $");
#endif /* LIBC_SCCS and not lint */
#include <sys/types.h>
@@ -53,9 +53,6 @@
register size_t n = siz;
size_t dlen;
- if (dst == NULL || src == NULL)
- return (0);
-
/* Find the end of dst and adjust bytes left but don't go past end */
while (*d != '\0' && n-- != 0)
d++;
diff -r f7291f58749b -r 1b79e0084d20 lib/libc/string/strlcpy.c
--- a/lib/libc/string/strlcpy.c Fri Sep 10 22:49:33 1999 +0000
+++ b/lib/libc/string/strlcpy.c Fri Sep 10 23:13:09 1999 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: strlcpy.c,v 1.2 1999/09/08 22:56:56 lukem Exp $ */
+/* $NetBSD: strlcpy.c,v 1.3 1999/09/10 23:13:09 lukem Exp $ */
/* from OpenBSD: strlcpy.c,v 1.4 1999/05/01 18:56:41 millert Exp */
/*
@@ -30,7 +30,7 @@
#include <sys/cdefs.h>
#if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: strlcpy.c,v 1.2 1999/09/08 22:56:56 lukem Exp $");
+__RCSID("$NetBSD: strlcpy.c,v 1.3 1999/09/10 23:13:09 lukem Exp $");
#endif /* LIBC_SCCS and not lint */
#include <sys/types.h>
@@ -51,9 +51,6 @@
register const char *s = src;
register size_t n = siz;
- if (dst == NULL || src == NULL)
- return (0);
-
/* Copy as many bytes as will fit */
if (n != 0 && --n != 0) {
do {
Home |
Main Index |
Thread Index |
Old Index