media/libvpx/mingw.patch
author Ryan VanderMeulen <ryanvm@gmail.com>
Mon, 07 Apr 2014 15:49:48 -0400
changeset 177376 8b87a6adad143376550d552cef67d733ebdf6c4c
parent 169713 62a6b1b8d6fa33d15d92c4890e377c30903308ca
permissions -rw-r--r--
Backed out changeset e35851f07b67 (bug 987508) for non-unified bustage.

diff --git a/media/libvpx/vpx/src/svc_encodeframe.c b/media/libvpx/vpx/src/svc_encodeframe.c
index 57d21dc..2514ad3 100644
--- a/media/libvpx/vpx/src/svc_encodeframe.c
+++ b/media/libvpx/vpx/src/svc_encodeframe.c
@@ -18,21 +18,23 @@
 #include <stdlib.h>
 #include <string.h>
 #define VPX_DISABLE_CTRL_TYPECHECKS 1
 #define VPX_CODEC_DISABLE_COMPAT 1
 #include "vpx/svc_context.h"
 #include "vpx/vp8cx.h"
 #include "vpx/vpx_encoder.h"
 
-#if defined(__MINGW32__) && !defined(MINGW_HAS_SECURE_API)
+#ifdef __MINGW32__
 #define strtok_r strtok_s
+#ifndef MINGW_HAS_SECURE_API
 // proto from /usr/x86_64-w64-mingw32/include/sec_api/string_s.h
 _CRTIMP char *__cdecl strtok_s(char *str, const char *delim, char **context);
-#endif
+#endif  /* MINGW_HAS_SECURE_API */
+#endif  /* __MINGW32__ */
 
 #ifdef _MSC_VER
 #define strdup _strdup
 #define strtok_r strtok_s
 #endif
 
 #define SVC_REFERENCE_FRAMES 8
 #define SUPERFRAME_SLOTS (8)