Android: NullPointerException on SimpleCursorAdapter.bindView() -
i experiencing crashes when using simplecursoradapter
. it's happening users having android 4.0.3 , 4.0.4, it's nasty interests 1% of users, not little.
it fixed on 19th june 2012, comment: "fix crash when simplecursoradapter changes cursor null when spinner's drop-down view shown." (this diff)
how can avoid crashes users still have android 4.0.3 , 4.0.4 ?
java.lang.nullpointerexception @ android.widget.simplecursoradapter.bindview(simplecursoradapter.java:150) @ android.widget.cursoradapter.getview(cursoradapter.java:250) @ android.widget.abslistview.obtainview(abslistview.java:2424) @ android.widget.listpopupwindow$dropdownlistview.obtainview(listpopupwindow.java:1168) @ android.widget.listview.measureheightofchildren(listview.java:1251) @ android.widget.listpopupwindow.builddropdown(listpopupwindow.java:1095) @ android.widget.listpopupwindow.show(listpopupwindow.java:524) @ android.widget.listpopupwindow$popupdatasetobserver.onchanged(listpopupwindow.java:1219) @ android.database.datasetobservable.notifychanged(datasetobservable.java:35) @ android.widget.baseadapter.notifydatasetchanged(baseadapter.java:50) @ android.widget.cursoradapter.swapcursor(cursoradapter.java:341) @ android.widget.simplecursoradapter.swapcursor(simplecursoradapter.java:347) @ android.widget.cursoradapter.changecursor(cursoradapter.java:309) @ android.widget.cursorfilter.publishresults(cursorfilter.java:67) @ android.widget.filter$resultshandler.handlemessage(filter.java:282) @ android.os.handler.dispatchmessage(handler.java:99) @ android.os.looper.loop(looper.java:137) @ android.app.activitythread.main(activitythread.java:4514) @ java.lang.reflect.method.invokenative(method.java) @ java.lang.reflect.method.invoke(method.java:511) @ com.android.internal.os.zygoteinit$methodandargscaller.run(zygoteinit.java:993) @ com.android.internal.os.zygoteinit.main(zygoteinit.java:760) @ dalvik.system.nativestart.main(nativestart.java)
Comments
Post a Comment