[libbluray-devel] BDJSecurityManager: silence failures from clipboard access

hpi1 git at videolan.org
Thu Sep 7 10:14:27 CEST 2017


libbluray | branch: master | hpi1 <hpi1 at anonymous.org> | Thu Sep  7 10:54:38 2017 +0300| [e7fa008705129e26624c8cb6a4c28597d0080e42] | committer: hpi1

BDJSecurityManager: silence failures from clipboard access

> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=e7fa008705129e26624c8cb6a4c28597d0080e42
---

 src/libbluray/bdj/java/org/videolan/BDJSecurityManager.java | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/src/libbluray/bdj/java/org/videolan/BDJSecurityManager.java b/src/libbluray/bdj/java/org/videolan/BDJSecurityManager.java
index fc7dfb35..76755602 100644
--- a/src/libbluray/bdj/java/org/videolan/BDJSecurityManager.java
+++ b/src/libbluray/bdj/java/org/videolan/BDJSecurityManager.java
@@ -189,6 +189,14 @@ final class BDJSecurityManager extends SecurityManager {
             return;
         }
 
+        else if (perm instanceof java.awt.AWTPermission) {
+            /* silence failures from clipboard access */
+            if (perm.getName().equals("accessClipboard")) {
+                java.security.AccessController.checkPermission(perm);
+                return;
+            }
+        }
+
         try {
             java.security.AccessController.checkPermission(perm);
         } catch (java.security.AccessControlException ex) {



More information about the libbluray-devel mailing list