This is an automated email from the ASF dual-hosted git repository.

bodewig pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-compress.git


The following commit(s) were added to refs/heads/master by this push:
     new 23b758f  COMPRESS-552 check interfaces of superclasses as well
23b758f is described below

commit 23b758fbe071f58eb2625e50166351bdb5983f13
Author: Stefan Bodewig <stefan.bode...@innoq.com>
AuthorDate: Sun May 16 12:04:18 2021 +0200

    COMPRESS-552 check interfaces of superclasses as well
---
 src/main/java/org/apache/commons/compress/utils/OsgiUtils.java | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/main/java/org/apache/commons/compress/utils/OsgiUtils.java 
b/src/main/java/org/apache/commons/compress/utils/OsgiUtils.java
index 3ec7c4e..a4e84b5 100644
--- a/src/main/java/org/apache/commons/compress/utils/OsgiUtils.java
+++ b/src/main/java/org/apache/commons/compress/utils/OsgiUtils.java
@@ -38,12 +38,12 @@ public class OsgiUtils {
             if (c.getName().equals("org.osgi.framework.BundleReference")) {
                 return true;
             }
-            c = c.getSuperclass();
-        }
-        for (Class<?> ifc : clazz.getInterfaces()) {
-            if (isBundleReference(ifc)) {
-                return true;
+            for (Class<?> ifc : c.getInterfaces()) {
+                if (isBundleReference(ifc)) {
+                    return true;
+                }
             }
+            c = c.getSuperclass();
         }
         return false;
     }

Reply via email to