[vlc-commits] [Git][videolan/vlc][3.0.17.4] 2 commits: contrib: upnp: do not try to detach detached thread

Hugo Beauzée-Luyssen (@chouquette) gitlab at videolan.org
Thu Mar 24 07:41:54 UTC 2022



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


Commits:
bb3bc8c7 by Steve Lhomme at 2022-03-22T16:50:33+01:00
contrib: upnp: do not try to detach detached thread

This is a cherry-pick of a patch in the 1.6.x branch that has not been released
yet.

(cherry picked from commit 4a44a134ac10a3bf57ae1bd679cad1d0a77f91a7)

Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>

- - - - -
c650ce1a by Hugo Beauzée-Luyssen at 2022-03-23T08:02:46+01:00
On the road to 3.0.17.4

- - - - -


4 changed files:

- NEWS
- configure.ac
- + contrib/src/upnp/0001-Do-not-try-to-detach-detached-thread-the-result-is-u.patch
- contrib/src/upnp/rules.mak


Changes:

=====================================
NEWS
=====================================
@@ -1,3 +1,9 @@
+Changes between 3.0.17.3 and 3.0.17.4:
+----------------------------------
+
+Service Discovery:
+ * Fix UPnP regression on Windows
+
 Changes between 3.0.17.2 and 3.0.17.3:
 ----------------------------------
 


=====================================
configure.ac
=====================================
@@ -2,11 +2,11 @@ dnl Autoconf settings for vlc
 
 AC_COPYRIGHT([Copyright 1999-2022 VLC authors and VideoLAN])
 
-AC_INIT(vlc, 3.0.17.3)
+AC_INIT(vlc, 3.0.17.4)
 VERSION_MAJOR=3
 VERSION_MINOR=0
 VERSION_REVISION=17
-VERSION_EXTRA=3
+VERSION_EXTRA=4
 VERSION_DEV=
 
 PKGDIR="vlc"


=====================================
contrib/src/upnp/0001-Do-not-try-to-detach-detached-thread-the-result-is-u.patch
=====================================
@@ -0,0 +1,30 @@
+From de5cd603acd5c81ec947fd9664817231a3d2c418 Mon Sep 17 00:00:00 2001
+From: Jean-Francois Dockes <jf at dockes.org>
+Date: Sun, 27 Jan 2019 10:44:17 +0100
+Subject: [PATCH] Do not try to detach detached thread, the result is
+ undefined. Fixes issue #102
+
+(cherry picked from commit 386b7ed79146ecf7a3bba49f48cb8f41a9b49170)
+---
+ threadutil/src/ThreadPool.c | 5 -----
+ 1 file changed, 5 deletions(-)
+
+diff --git a/threadutil/src/ThreadPool.c b/threadutil/src/ThreadPool.c
+index fcf71087..8c6cd092 100644
+--- a/threadutil/src/ThreadPool.c
++++ b/threadutil/src/ThreadPool.c
+@@ -651,11 +651,6 @@ static int CreateWorker(
+ 	rc = ithread_create(&temp, &attr, WorkerThread, tp);
+ 	ithread_attr_destroy(&attr);
+ 	if (rc == 0) {
+-		rc = ithread_detach(temp);
+-		/* ithread_detach will return EINVAL if thread has been
+-		 successfully detached by ithread_create */
+-		if (rc == EINVAL)
+-			rc = 0;
+ 		tp->pendingWorkerThreadStart = 1;
+ 		/* wait until the new worker thread starts */
+ 		while (tp->pendingWorkerThreadStart) {
+-- 
+2.27.0.windows.1
+


=====================================
contrib/src/upnp/rules.mak
=====================================
@@ -28,6 +28,7 @@ endif
 
 upnp: libupnp-$(UPNP_VERSION).tar.bz2 .sum-upnp
 	$(UNPACK)
+	$(APPLY) $(SRC)/upnp/0001-Do-not-try-to-detach-detached-thread-the-result-is-u.patch
 ifdef HAVE_WIN32
 	$(APPLY) $(SRC)/upnp/libupnp-win32.patch
 	$(APPLY) $(SRC)/upnp/libupnp-win64.patch



View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/426513d88e3e3dc671434db8e724ee5d1b7e1038...c650ce1a4e352cc04192229a8878b8b6c312527d

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/426513d88e3e3dc671434db8e724ee5d1b7e1038...c650ce1a4e352cc04192229a8878b8b6c312527d
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