[vlc-commits] [Git][videolan/vlc][master] contrib: upnp: remove wrong win32 safe wrappers

Hugo Beauzée-Luyssen (@chouquette) gitlab at videolan.org
Sat Sep 17 16:44:54 UTC 2022



Hugo Beauzée-Luyssen pushed to branch master at VideoLAN / VLC


Commits:
751e0007 by Alaric Senat at 2022-09-17T15:52:15+00:00
contrib: upnp: remove wrong win32 safe wrappers

Theses wrapper were too naively written and are causing a lot of
regressions on windows.

This has been addressed upstream [1]. And is simply reverted for now,
waiting for a new release.

Fixes #27306

[1] https://github.com/pupnp/pupnp/issues/411

- - - - -


2 changed files:

- contrib/src/upnp/rules.mak
- + contrib/src/upnp/win32-remove-wrong-safe-wrappers.patch


Changes:

=====================================
contrib/src/upnp/rules.mak
=====================================
@@ -42,6 +42,7 @@ ifdef HAVE_WIN32
 	$(APPLY) $(SRC)/upnp/libupnp-win32.patch
 	$(APPLY) $(SRC)/upnp/windows-version-inet.patch
 	$(APPLY) $(SRC)/upnp/0001-ThreadPool-Fix-non-UCRT-builds.patch
+	$(APPLY) $(SRC)/upnp/win32-remove-wrong-safe-wrappers.patch
 endif
 ifdef HAVE_LINUX
 ifndef HAVE_ANDROID


=====================================
contrib/src/upnp/win32-remove-wrong-safe-wrappers.patch
=====================================
@@ -0,0 +1,35 @@
+From 90dee7da8ed96ea6e2ade2dd0f085bfb575449b3 Mon Sep 17 00:00:00 2001
+From: Alaric Senat <dev.asenat at posteo.net>
+Date: Tue, 13 Sep 2022 19:48:09 +0200
+Subject: [PATCH] win32: remove wrong safe wrappers
+
+Theses wrapper were too naively written and are causing a lot of
+regressions on windows.
+
+This has been addressed upstream [1]. And is simply reverted for now,
+waiting for a new release.
+
+[1] https://github.com/pupnp/pupnp/issues/411
+---
+ ixml/inc/posix_overwrites.h | 6 ------
+ 1 file changed, 6 deletions(-)
+
+diff --git a/ixml/inc/posix_overwrites.h b/ixml/inc/posix_overwrites.h
+index a9c49e3f..7e37a355 100644
+--- a/ixml/inc/posix_overwrites.h
++++ b/ixml/inc/posix_overwrites.h
+@@ -11,11 +11,5 @@
+ 	#define strncasecmp strnicmp
+ 	#define strnicmp _strnicmp
+ 
+-	/* Secure versions of functions */
+-	#define strcat(arg1, arg2) strcat_s(arg1, sizeof(arg1), arg2)
+-	#define strcpy(arg1, arg2) strcpy_s(arg1, _countof(arg1), arg2)
+-	#define strncpy(arg1, arg2, arg3) strncpy_s(arg1, arg3, arg2, arg3)
+-	#define sprintf(arg1, ...) sprintf_s(arg1, sizeof(arg1), __VA_ARGS__)
+-
+ #endif /* _WIN32 */
+ #endif /* POSIX_OVERWRTIES_H */
+-- 
+2.35.1
+



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/751e0007e75da2fceba2f5d9f797db60eaef1db4

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/751e0007e75da2fceba2f5d9f797db60eaef1db4
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list