Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] App Crash: NullPointerException #1543

Closed
DrAnonym666 opened this issue Dec 21, 2024 · 5 comments
Closed

[Bug] App Crash: NullPointerException #1543

DrAnonym666 opened this issue Dec 21, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@DrAnonym666
Copy link

Device: 23124RA7EO (Redmi - sapphiren), SDK: 34 (14), App: 3.1.1 (161)

java.lang.NullPointerException: Attempt to read from field 'int android.view.View.mViewFlags' on a null object reference in method 'void android.view.ViewGroup.dispatchDraw(android.graphics.Canvas)'
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4379)
at android.view.View.draw(View.java:24735)
at com.android.internal.policy.DecorView.draw(DecorView.java:896)
at android.view.View.updateDisplayListIfDirty(View.java:23563)
at android.view.ThreadedRenderer.updateViewTreeDisplayList(ThreadedRenderer.java:726)
at android.view.ThreadedRenderer.updateRootDisplayList(ThreadedRenderer.java:735)
at android.view.ThreadedRenderer.draw(ThreadedRenderer.java:845)
at android.view.ViewRootImpl.draw(ViewRootImpl.java:5622)
at android.view.ViewRootImpl.performDraw(ViewRootImpl.java:5301)
at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:4425)
at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:2995)
at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:10331)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1594)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1603)
at android.view.Choreographer.doCallbacks(Choreographer.java:1125)
at android.view.Choreographer.doFrame(Choreographer.java:1030)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1567)
at android.os.Handler.handleCallback(Handler.java:958)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loopOnce(Looper.java:224)
at android.os.Looper.loop(Looper.java:318)
at android.app.ActivityThread.main(ActivityThread.java:8763)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:561)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1013)

What to Do? Every time after edit picture or save picture this comes. Picture is saved, but its a lol bit Confusing.

Tested with github Version, playstore Version and f-droid... Oh pardon... Telegramm app Tested too. What should i Do?

@DrAnonym666 DrAnonym666 added the bug Something isn't working label Dec 21, 2024
@T8RIN
Copy link
Owner

T8RIN commented Dec 21, 2024

could you send export og your settings?

@T8RIN
Copy link
Owner

T8RIN commented Dec 21, 2024

also which screen exactly causes this?

@T8RIN
Copy link
Owner

T8RIN commented Dec 21, 2024

Also please try on the latest CI actions build

Bharath-Dhakar added a commit to Bharath-Dhakar/ImageToolbox that referenced this issue Jan 17, 2025
Fixes T8RIN#1543

Add null checks to prevent NullPointerException in `dispatchDraw` method.

* **AppActivity.kt**
  - Add null check for `View` object in `dispatchDraw` method to prevent null pointer dereference.
  - Ensure `View` object is properly initialized before accessing its fields.

* **ImageContainer.kt, ImagePager.kt, ImagePreviewGrid.kt, ImagesPreviewWithSelection.kt, ImageStickyHeader.kt, Picture.kt, SimplePicture.kt, UrisCarousel.kt, UrisPreview.kt**
  - Add null check for `View` object in `dispatchDraw` method to prevent null pointer dereference.
  - Ensure `View` object is properly initialized before accessing its fields.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/T8RIN/ImageToolbox/issues/1543?shareId=XXXX-XXXX-XXXX-XXXX).
@T8RIN
Copy link
Owner

T8RIN commented Jan 17, 2025

@T8RIN
Copy link
Owner

T8RIN commented Jan 19, 2025

i think it's fixed withing last jetpack compose alpha

@T8RIN T8RIN closed this as completed Jan 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants