Uploaded image for project: 'Couchbase Lite'
  1. Couchbase Lite
  2. CBL-272

MessageSocketFactory.socket_open() is not accessible by C4Socket

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 2.7.0
    • None
    • Java-Android
    • Security Level: Public
    • None
    • CBL Sprint 1
    • 3

    Description

      com.couchbase.lite.MessageSocketFactory has package level accessor so it cannot be seen by com.couchbase.lite.internal.core.C4Socket. The socket_open() is called by using reflection which somehow works on Android but not Java. In theory, it shouldn't be working for Android too.

      Exception:

      Exception in thread "Thread-3" java.lang.RuntimeException: socket_open() method is not accessible
      	at com.couchbase.lite.internal.core.C4Socket.open(C4Socket.java:146)
      Caused by: java.lang.IllegalAccessException: class com.couchbase.lite.internal.core.C4Socket cannot access a member of class com.couchbase.lite.MessageSocketFactory with modifiers "public static"
      	at java.base/jdk.internal.reflect.Reflection.newIllegalAccessException(Reflection.java:361)
      	at java.base/java.lang.reflect.AccessibleObject.checkAccess(AccessibleObject.java:591)
      

      Attachments

        Activity

          People

            pasin Pasin Suriyentrakorn
            pasin Pasin Suriyentrakorn
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              PagerDuty