Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src make the 2nd argument to __memmove_chk() const



details:   https://anonhg.NetBSD.org/src/rev/3f9642fa0fe5
branches:  trunk
changeset: 943518:3f9642fa0fe5
user:      mrg <mrg%NetBSD.org@localhost>
date:      Sat Sep 05 13:37:59 2020 +0000

description:
make the 2nd argument to __memmove_chk() const

diffstat:

 include/ssp/string.h       |  4 ++--
 lib/libc/ssp/memmove_chk.c |  8 ++++----
 2 files changed, 6 insertions(+), 6 deletions(-)

diffs (49 lines):

diff -r ca8490e05f31 -r 3f9642fa0fe5 include/ssp/string.h
--- a/include/ssp/string.h      Sat Sep 05 13:36:49 2020 +0000
+++ b/include/ssp/string.h      Sat Sep 05 13:37:59 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: string.h,v 1.13 2014/11/29 13:23:48 pooka Exp $        */
+/*     $NetBSD: string.h,v 1.14 2020/09/05 13:37:59 mrg Exp $  */
 
 /*-
  * Copyright (c) 2006 The NetBSD Foundation, Inc.
@@ -36,7 +36,7 @@
 
 __BEGIN_DECLS
 void *__memcpy_chk(void *, const void *, size_t, size_t);
-void *__memmove_chk(void *, void *, size_t, size_t);
+void *__memmove_chk(void *, const void *, size_t, size_t);
 void *__memset_chk(void *, int, size_t, size_t);
 char *__stpcpy_chk(char *, const char *, size_t);
 char *__strcat_chk(char *, const char *, size_t);
diff -r ca8490e05f31 -r 3f9642fa0fe5 lib/libc/ssp/memmove_chk.c
--- a/lib/libc/ssp/memmove_chk.c        Sat Sep 05 13:36:49 2020 +0000
+++ b/lib/libc/ssp/memmove_chk.c        Sat Sep 05 13:37:59 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: memmove_chk.c,v 1.5 2014/09/17 00:39:28 joerg Exp $    */
+/*     $NetBSD: memmove_chk.c,v 1.6 2020/09/05 13:37:59 mrg Exp $      */
 
 /*-
  * Copyright (c) 2006 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: memmove_chk.c,v 1.5 2014/09/17 00:39:28 joerg Exp $");
+__RCSID("$NetBSD: memmove_chk.c,v 1.6 2020/09/05 13:37:59 mrg Exp $");
 
 /*LINTLIBRARY*/
 
@@ -38,10 +38,10 @@
 
 #undef memmove
 
-void *__memmove_chk(void *, void *src, size_t, size_t);
+void *__memmove_chk(void *, const void *src, size_t, size_t);
 
 void *
-__memmove_chk(void *dst, void *src, size_t len,
+__memmove_chk(void *dst, const void *src, size_t len,
     size_t slen)
 {
        if (len > slen)



Home | Main Index | Thread Index | Old Index