java.lang.NullPointerException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • I can't get openPhotoGallery to work on Android since upgrading to 6.0.0. The gallery opens fine, but when an image is selected, and I try to read the blob, I'm getting the following error: {code:java} [WARN] : W/System.err: java.lang.NullPointerException: Attempt to invoke virtual method 'char[] java.lang.String.toCharArray()' on a null object reference [WARN] : W/System.err: at java.io.File.fixSlashes(File.java:183) [WARN] : W/System.err: at java.io.File.<init>(File.java:130) [WARN] : W/System.err: at org.appcelerator.titanium.io.TitaniumBlob.getFile(TitaniumBlob.java:77) [WARN] : W/System.err: at org.appcelerator.titanium.TiBlob.getLength(TiBlob.java:364) [WARN] : W/System.err: at org.appcelerator.kroll.runtime.v8.V8Function.nativeInvoke(Native Method) [WARN] : W/System.err: at org.appcelerator.kroll.runtime.v8.V8Function.callSync(V8Function.java:57) [WARN] : W/System.err: at org.appcelerator.kroll.runtime.v8.V8Function.call(V8Function.java:43) [WARN] : W/System.err: at org.appcelerator.kroll.runtime.v8.V8Function$1.run(V8Function.java:70) [WARN] : W/System.err: at android.os.Handler.handleCallback(Handler.java:739) [WARN] : W/System.err: at android.os.Handler.dispatchMessage(Handler.java:95) [WARN] : W/System.err: at android.os.Looper.loop(Looper.java:148) [WARN] : W/System.err: at org.appcelerator.kroll.KrollRuntime$KrollRuntimeThread.run(KrollRuntime.java:118) [WARN] : EGL_emulation: eglSurfaceAttrib not implemented [WARN] : OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0xdc79b4e0, error=EGL_SUCCESS [ERROR] : TiExceptionHandler: (main) [20134,28149] ----- Titanium Javascript Runtime Error ----- [ERROR] : TiExceptionHandler: (main) [0,28149] - In undefined:230,23 [ERROR] : TiExceptionHandler: (main) [0,28149] - Message: Uncaught Attempt to invoke virtual method 'char[] java.lang.String.toCharArray()' on a null object reference [ERROR] : TiExceptionHandler: (main) [1,28150] - Source: if (me.attachedImage.length > 5242880) { [WARN] : EGL_emulation: eglSurfaceAttrib not implemented [WARN] : OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0xe8e3e9a0, error=EGL_SUCCESS {code}
    via by David Fox,
    • java.lang.NullPointerException: Attempt to invoke virtual method 'char[] java.lang.String.toCharArray()' on a null object reference at java.io.File.fixSlashes(File.java:183) at java.io.File.<init>(File.java:130) at com.omnom.fragments.pages.PageTakeMedia.onImagesChosen(PageTakeMedia.java:422) at com.kbeanie.multipicker.core.threads.ImageProcessorThread$1.run(ImageProcessorThread.java:52) at android.os.Handler.handleCallback(Handler.java:739) at android.os.Handler.dispatchMessage(Handler.java:95) at android.os.Looper.loop(Looper.java:158) at android.app.ActivityThread.main(ActivityThread.java:7225) at java.lang.reflect.Method.invoke(Method.java) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)

    Users with the same issue

    Hiren AmaliyarHiren Amaliyar
    2 times, last one,
    Indri YunitaIndri Yunita
    8 times, last one,
    ajinkya_wajinkya_w
    1 times, last one,
    Diogo JaymDiogo Jaym
    6 times, last one,
    ben.slama.jihedben.slama.jihed
    6 times, last one,
    44 more bugmates