Module Name:    src
Committed By:   tls
Date:           Sun Aug 10 06:51:40 UTC 2014

Modified Files:
        src/include/ssp [tls-earlyentropy]: string.h

Log Message:
Rebase.


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.9.2.1 src/include/ssp/string.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/include/ssp/string.h
diff -u src/include/ssp/string.h:1.9 src/include/ssp/string.h:1.9.2.1
--- src/include/ssp/string.h:1.9	Thu Nov  7 02:00:54 2013
+++ src/include/ssp/string.h	Sun Aug 10 06:51:40 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: string.h,v 1.9 2013/11/07 02:00:54 christos Exp $	*/
+/*	$NetBSD: string.h,v 1.9.2.1 2014/08/10 06:51:40 tls Exp $	*/
 
 /*-
  * Copyright (c) 2006 The NetBSD Foundation, Inc.
@@ -31,6 +31,7 @@
 #ifndef _SSP_STRING_H_
 #define _SSP_STRING_H_
 
+#include <sys/cdefs.h>
 #include <ssp/ssp.h>
 
 __BEGIN_DECLS
@@ -82,6 +83,7 @@ __ssp_bos_icheck3_restrict(memcpy, void 
 __ssp_bos_icheck3(memmove, void *, const void *)
 __ssp_bos_icheck3(memset, void *, int)
 __ssp_bos_icheck2_restrict(stpcpy, char *, const char *)
+__ssp_bos_icheck3_restrict(stpncpy, char *, const char *)
 __ssp_bos_icheck2_restrict(strcpy, char *, const char *)
 __ssp_bos_icheck2_restrict(strcat, char *, const char *)
 __ssp_bos_icheck3_restrict(strncpy, char *, const char *)
@@ -92,6 +94,9 @@ __END_DECLS
 #define memmove(dst, src, len) __ssp_bos_check3(memmove, dst, src, len)
 #define memset(dst, val, len) __ssp_bos_check3(memset, dst, val, len)
 #define stpcpy(dst, src) __ssp_bos_check2(stpcpy, dst, src)
+#if __GNUC_PREREQ__(4,8) || defined(__clang__)
+#define stpncpy(dst, src, len) __ssp_bos_check3(stpncpy, dst, src, len)
+#endif
 #define strcpy(dst, src) __ssp_bos_check2(strcpy, dst, src)
 #define strcat(dst, src) __ssp_bos_check2(strcat, dst, src)
 #define strncpy(dst, src, len) __ssp_bos_check3(strncpy, dst, src, len)

Reply via email to