[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [sandboxed-tor-browser/master] Bug 20806: Try even harder to exclude gstreamer.



commit ba904904e692acbafe8c38bda916724bcfbce68c
Author: Yawning Angel <yawning@xxxxxxxxxxxxxxx>
Date:   Sat Dec 10 19:00:33 2016 +0000

    Bug 20806: Try even harder to exclude gstreamer.
    
    The workaround I added for weird systems that pull in gstreamer was
    coded slightly wrong, in that allowing ffmpeg was sufficient to pull in
    gstreamer as a dependency.
    
    I'm not aware of any system that will do this, so it's livable for 0.0.2,
    but this is more correct.
---
 ChangeLog                                                |  1 +
 .../internal/sandbox/application.go                      | 16 ++++++++--------
 2 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index f98af08..6425234 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,5 @@
 Changes in version 0.0.3 - UNRELEASED:
+ * Bug 20806: Try even harder to exclude gstreamer.
 
 Changes in version 0.0.2 - 2016-12-10:
  * Bug #20780: Shuffle and persist the ordering of internal bridges.
diff --git a/src/cmd/sandboxed-tor-browser/internal/sandbox/application.go b/src/cmd/sandboxed-tor-browser/internal/sandbox/application.go
index 8895a36..119f7ef 100644
--- a/src/cmd/sandboxed-tor-browser/internal/sandbox/application.go
+++ b/src/cmd/sandboxed-tor-browser/internal/sandbox/application.go
@@ -285,14 +285,14 @@ func filterCodecs(fn string, allowFfmpeg bool) error {
 	_, fn = filepath.Split(fn)
 	lfn := strings.ToLower(fn)
 
-	codecPrefixes := []string{}
-	if !allowGstreamer && !allowFfmpeg {
-		// Unless overridden, gstreamer is explicitly prohibited.
-		codecPrefixes = append(codecPrefixes, []string{
-			"libstreamer",
-			"libgstapp",
-			"libgstvideo",
-		}...)
+	// Unless overridden, gstreamer is explicitly prohibited.
+	codecPrefixes := []string{
+		"libstreamer",
+		"libgstapp",
+		"libgstvideo",
+	}
+	if allowGstreamer && allowFfmpeg {
+		codecPrefixes = []string{}
 	}
 	if !allowFfmpeg {
 		codecPrefixes = append(codecPrefixes, "libavcodec")

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits