Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libc/ssp handle old gcc
details: https://anonhg.NetBSD.org/src/rev/e5f4bfb4cb40
branches: trunk
changeset: 791137:e5f4bfb4cb40
user: christos <christos%NetBSD.org@localhost>
date: Wed Nov 06 16:58:58 2013 +0000
description:
handle old gcc
diffstat:
lib/libc/ssp/stpcpy_chk.c | 8 ++++++--
lib/libc/ssp/stpncpy_chk.c | 8 ++++++--
2 files changed, 12 insertions(+), 4 deletions(-)
diffs (58 lines):
diff -r dcd7cbbad5d7 -r e5f4bfb4cb40 lib/libc/ssp/stpcpy_chk.c
--- a/lib/libc/ssp/stpcpy_chk.c Wed Nov 06 16:49:21 2013 +0000
+++ b/lib/libc/ssp/stpcpy_chk.c Wed Nov 06 16:58:58 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: stpcpy_chk.c,v 1.1 2013/11/06 16:31:08 christos Exp $ */
+/* $NetBSD: stpcpy_chk.c,v 1.2 2013/11/06 16:58:58 christos Exp $ */
/*-
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
* POSSIBILITY OF SUCH DAMAGE.
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: stpcpy_chk.c,v 1.1 2013/11/06 16:31:08 christos Exp $");
+__RCSID("$NetBSD: stpcpy_chk.c,v 1.2 2013/11/06 16:58:58 christos Exp $");
/*LINTLIBRARY*/
@@ -38,6 +38,10 @@
#undef memcpy
+#if !__GNUC_PREREQ__(4, 8)
+char *__stpcpy_chk(char * __restrict, const char * __restrict, size_t);
+#endif
+
char *
__stpcpy_chk(char * __restrict dst, const char * __restrict src, size_t slen)
{
diff -r dcd7cbbad5d7 -r e5f4bfb4cb40 lib/libc/ssp/stpncpy_chk.c
--- a/lib/libc/ssp/stpncpy_chk.c Wed Nov 06 16:49:21 2013 +0000
+++ b/lib/libc/ssp/stpncpy_chk.c Wed Nov 06 16:58:58 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: stpncpy_chk.c,v 1.1 2013/11/06 16:31:08 christos Exp $ */
+/* $NetBSD: stpncpy_chk.c,v 1.2 2013/11/06 16:58:58 christos Exp $ */
/*-
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
* POSSIBILITY OF SUCH DAMAGE.
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: stpncpy_chk.c,v 1.1 2013/11/06 16:31:08 christos Exp $");
+__RCSID("$NetBSD: stpncpy_chk.c,v 1.2 2013/11/06 16:58:58 christos Exp $");
/*LINTLIBRARY*/
@@ -38,6 +38,10 @@
#undef stpncpy
+#if !__GNUC_PREREQ__(4, 8)
+char *__stpncpy_chk(char * __restrict, const char * __restrict, size_t, size_t);
+#endif
+
char *
__stpncpy_chk(char * __restrict dst, const char * __restrict src, size_t len,
size_t slen)
Home |
Main Index |
Thread Index |
Old Index