jaysh / xposed-whatsapp

Add functional improvements to the mainstream WhatsApp Android application.
MIT License
40 stars 13 forks source link

Emoji crash #26

Closed ghost closed 9 years ago

ghost commented 9 years ago

For some odd reason this only happens when your module is enabled. All emoji from the window disappear and then after 5 seconds app crashes. Since you were inactive, I had disabled the module. Hope you manage to fix this

ghost commented 9 years ago

10-14 00:09:15.459 E/AndroidRuntime(9651): FATAL EXCEPTION: Thread-342 10-14 00:09:15.459 E/AndroidRuntime(9651): Process: com.whatsapp, PID: 9651 10-14 00:09:15.459 E/AndroidRuntime(9651): java.lang.OutOfMemoryError 10-14 00:09:15.459 E/AndroidRuntime(9651): at android.graphics.BitmapFactory.nativeDecodeStream(Native Method) 10-14 00:09:15.459 E/AndroidRuntime(9651): at android.graphics.BitmapFactory.decodeStreamInternal(BitmapFactory.java:620) 10-14 00:09:15.459 E/AndroidRuntime(9651): at android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:596) 10-14 00:09:15.459 E/AndroidRuntime(9651): at android.graphics.BitmapFactory.decodeFile(BitmapFactory.java:376) 10-14 00:09:15.459 E/AndroidRuntime(9651): at com.whatsapp.util.b4.run(b4.java:4) 10-14 00:09:18.809 E/dalvikvm(12376): Could not find class 'com.amazon.device.messaging.ADM', referenced from method com.whatsapp.App.h 10-14 00:09:18.809 E/dalvikvm(12376): Could not find class 'com.amazon.device.messaging.ADM', referenced from method com.whatsapp.App.l 10-14 00:09:18.959 E/dalvikvm(12376): Could not find class 'com.whatsapp.adm.ADMMessageHandler', referenced from method com.whatsapp.a5.d 10-14 00:09:18.959 E/dalvikvm(12376): Could not find class 'com.whatsapp.adm.ADMMessageHandler', referenced from method com.whatsapp.a5.d

jaysh commented 9 years ago

Thank you for the report and backtrace. If this java.lang.OutOfMemoryError only happens when this module is active, it must be a memory leak of sorts.

How often do you see this? Immediately after re-enabling it, or 1 day, 1 week, etc.?

ghost commented 9 years ago

Immediately. I had disabled your module for several days and this didn't happen. Enabled today to grab the log for the other error I mentioned and it started crashing again.

jaysh commented 9 years ago

I see. A thought just occurred to me that might help us address both of your problems: can you disable ALL of the features but leave the module enabled? Then slowly, perhaps over the course of days, you enable them one by one to isolate which feature (or combination) is causing the issue?

Would you mind telling me approximately how many WhatsApp contacts you have? I am wondering if you have so many, it's trouble tracking all of the contacts in the map and running out of memory :)

ghost commented 9 years ago

Sure I'll do that and let you know

32 contacts. Is that too much? Not in active conversation with everyone though (if that matters)

jaysh commented 9 years ago

Thanks, that'll be really useful to me.

I have a similar statistics, so I wouldn't imagine it would cause a problem. How much RAM do you have in your device?

ghost commented 9 years ago

1 GB

jaysh commented 9 years ago

I doubt it's a RAM issue then.

Have you had any luck on narrowing down the cause?

ghost commented 9 years ago

No luck really. It stopped crashing though. But the emoji board still becomes empty sometimes. I have to restart the app when that happens. And keep contacts in history is not working at all

jaysh commented 9 years ago

Fair enough. Did you get a chance to try enabling them one by one to see which one is being problematic?

ghost commented 9 years ago

Yes I did try many combinations. Both problems occur irrespective of what I choose

jaysh commented 9 years ago

Okay, that's good to know. So just to confirm: if you disable every mod, it still causes the Emoji issues? If that's the case, then that narrows it into code that sits outside any individual modules (which should be a minimal amount) so I know where to start looking.

I do know how much RAM you have, but can you share:

Ideally, I would try and get my hands on the device somehow and reproduce it so I can properly diagnose and fix it.

Thanks, Jay

ghost commented 9 years ago

I'll give it one more try and let you know. This emoji problem had diminished after my latest attempts to narrow down the error. Whatsapp stopped crashing but as I said nothing in the emoji board. And I have an Xperia S with Paranoid Android custom ROM running Android 4.4.4. And I haven't restricted Whatsapp in any way.

jaysh commented 9 years ago

Closing as per #23.