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

Apps Sometimes Crash due to ConcurrentModificationException

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • None
    • cordova-android
    • None

    Description

      Came across this when refactoring splashscreen plugin.

      Because plugins are lazily instantiated, and because plugins execute on non-ui thread by default, if a plugin calls "getPlugin()" while the ui thread is dispatching an onMessage (or one of the various other plugin functions), then the

      for (CordovaPlugin p : pluginMap.values())
      

      fires an exception due to getPlugin() modifying the map.

      Attachments

        Issue Links

          Activity

            People

              agrieve Andrew Grieve
              agrieve Andrew Grieve
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: