[libbluray-devel] Check for null

hpi1 git at videolan.org
Mon Sep 8 23:17:59 CEST 2014


libbluray | branch: master | hpi1 <hpi1 at anonymous.org> | Mon Sep  8 14:22:04 2014 +0300| [8b2c4f7de2f8b9897b10d9123500900d54f8f459] | committer: hpi1

Check for null

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

 src/libbluray/bdj/java/javax/tv/media/MediaSelectPermission.java     |    2 ++
 .../bdj/java/javax/tv/service/selection/SelectPermission.java        |    2 ++
 2 files changed, 4 insertions(+)

diff --git a/src/libbluray/bdj/java/javax/tv/media/MediaSelectPermission.java b/src/libbluray/bdj/java/javax/tv/media/MediaSelectPermission.java
index 1139569..3f00acf 100644
--- a/src/libbluray/bdj/java/javax/tv/media/MediaSelectPermission.java
+++ b/src/libbluray/bdj/java/javax/tv/media/MediaSelectPermission.java
@@ -46,6 +46,8 @@ public final class MediaSelectPermission extends Permission
     }
 
     public boolean equals(Object obj) {
+        if (obj == null)
+            return false;
         if (this == obj)
             return true;
         if (getClass() != obj.getClass())
diff --git a/src/libbluray/bdj/java/javax/tv/service/selection/SelectPermission.java b/src/libbluray/bdj/java/javax/tv/service/selection/SelectPermission.java
index eaeefc3..bee26cb 100644
--- a/src/libbluray/bdj/java/javax/tv/service/selection/SelectPermission.java
+++ b/src/libbluray/bdj/java/javax/tv/service/selection/SelectPermission.java
@@ -63,6 +63,8 @@ public final class SelectPermission extends Permission implements Serializable {
 
     public boolean equals(Object obj)
     {
+        if (obj == null)
+            return false;
         if (this == obj)
             return true;
         if (getClass() != obj.getClass())



More information about the libbluray-devel mailing list