Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-7265

Application built with Cordova 3.5.1 running on a device with Android < 4.0.3 crashes when the webview is redirected to a custom url scheme

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.5.0
    • None
    • cordova-android
    • None

    Description

      To reproduce add the jsHybugger plugin (https://github.com/jsHybugger/cordova-plugin-jshybugger) to any Cordova application and run it on an Android device with version < 4.0.3. The reason for the crash is the missing "android.content.Intent.setSelector" method:

      FATAL EXCEPTION: main
      java.lang.NoSuchMethodError: android.content.Intent.setSelector
      at org.apache.cordova.CordovaUriHelper.shouldOverrideUrlLoading(CordovaUriHelper.java:103)
      at org.apache.cordova.CordovaWebViewClient.shouldOverrideUrlLoading(CordovaWebViewClient.java:131)
      at android.webkit.CallbackProxy.uiOverrideUrlLoading(CallbackProxy.java:218)
      at android.webkit.CallbackProxy.handleMessage(CallbackProxy.java:337)
      at android.os.Handler.dispatchMessage(Handler.java:99)
      at android.os.Looper.loop(Looper.java:123)
      at android.app.ActivityThread.main(ActivityThread.java:3691)
      at java.lang.reflect.Method.invokeNative(Native Method)
      at java.lang.reflect.Method.invoke(Method.java:507)
      at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:847)
      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:605)
      at dalvik.system.NativeStart.main(Native Method)

      Attachments

        Activity

          People

            mbektchiev Martin Bektchiev
            mbektchiev Martin Bektchiev
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: