DImuthuUpe / AndroidPdfViewer

Android view for displaying PDFs rendered with PdfiumAndroid
Apache License 2.0
8.18k stars 1.91k forks source link

(3.0.0-beta.5) E/com.shockwave.pdfium.PdfiumCore: mContext may be null #512

Open gustavohansen opened 6 years ago

gustavohansen commented 6 years ago

I'm getting the next error when Scrolling a RecyclerView (Each row has a PDF and I'm using the 3.0.0-beta.5). It happens when I scroll with out waiting to the pdf to load, If I wait works fine.

E/com.shockwave.pdfium.PdfiumCore: mContext may be null
W/System.err: java.lang.NullPointerException: Attempt to invoke virtual method 'long java.lang.Long.longValue()' on a null object reference
W/System.err:     at com.shockwave.pdfium.PdfiumCore.renderPageBitmap(PdfiumCore.java:310)
W/System.err:     at com.github.barteksc.pdfviewer.PdfFile.renderPageBitmap(PdfFile.java:238)
W/System.err:     at com.github.barteksc.pdfviewer.RenderingHandler.proceed(RenderingHandler.java:109)
W/System.err:     at com.github.barteksc.pdfviewer.RenderingHandler.handleMessage(RenderingHandler.java:66)
W/System.err:     at android.os.Handler.dispatchMessage(Handler.java:102)
W/System.err:     at android.os.Looper.loop(Looper.java:154)
W/System.err:     at android.os.HandlerThread.run(HandlerThread.java:61)
Acorde commented 1 year ago

Have the same issue. Did you solve it?