0ad: wcsnlen(3) is missing in NetBSD

This commit is contained in:
Kamil Rytarowski 2016-10-15 00:55:31 +02:00
parent 52a1cf5ee0
commit f112a14432
2 changed files with 14 additions and 0 deletions

View File

@ -19,4 +19,5 @@ SHA1 (patch-libraries_source_nvtt_src_src_nvcore_nvcore.h) = 2cd3f056b75172ae5e1
SHA1 (patch-libraries_source_nvtt_src_src_nvcore_poshlib_posh.h) = b0759ead96db78237c5fa400cf320ab02e8b262b
SHA1 (patch-libraries_source_nvtt_src_src_nvmath_nvmath.h) = 218723373dc9f117eca33960cac045acc0eee97a
SHA1 (patch-source_graphics_TextureConverter.cpp) = d4e3920cd507468adc37dc92e27e6cbb50b5c5e2
SHA1 (patch-source_lib_secure__crt.cpp) = 1e56aa627c8f2343884968ab4ebd4b4eec73b777
SHA1 (patch-source_third__party_mikktspace_weldmesh.cpp) = 35df7dd5d5d2aa784ef03599a47cc69982ebe332

View File

@ -0,0 +1,13 @@
$NetBSD$
--- source/lib/secure_crt.cpp.orig 2015-01-24 00:22:12.000000000 +0000
+++ source/lib/secure_crt.cpp
@@ -112,7 +112,7 @@ STATUS_ADD_DEFINITIONS(secureCrtStatusDe
// self-test and the t* defines (needed for test).
#if EMULATE_SECURE_CRT
-#if !OS_UNIX || OS_MACOSX || OS_OPENBSD
+#if !OS_UNIX || OS_MACOSX || OS_OPENBSD || defined(__NetBSD__) /* XXX: Add wcsnlen(3) in NetBSD */
// return length [in characters] of a string, not including the trailing
// null character. to protect against access violations, only the
// first <max_len> characters are examined; if the null character is