gujjwal00 / avnc

VNC Client for Android
GNU General Public License v3.0
600 stars 57 forks source link

[BUG?] AVNC crashed on an Android 6.0 tv box #240

Closed fish4terrisa-MSDSM closed 2 months ago

fish4terrisa-MSDSM commented 2 months ago

I've hacked my tv box and flashed aosp firmware. And I installed AVNC on it so that I can use it to behave as a second screen for my linux pc. However, when I connect to my vnc server at the first time, it (seems that it )cannot load the first time tips successfully and crashed. Here's the log:

log

```python --------- beginning of main 07-16 22:26:47.825 1967 1978 I DualScreen: ApplicationThreadNative->scheduleLaunchActivity->taskId:17 07-16 22:26:47.982 1967 1967 W art : Before Android 4.1, method android.graphics.drawable.Drawable com.google.android.material.progressindicator.BaseProgressIndicator.getCurrentDrawable() would have incorrectly overridden the package-private method in android.widget.ProgressBar 07-16 22:26:48.000 1967 2305 I NativeVnc: Received protocol version 3.8 07-16 22:26:48.000 1967 2305 I NativeVnc: VNC server supports protocol version 3.8 (viewer 3.8) 07-16 22:26:48.005 1967 2305 I NativeVnc: We have 1 security types to read 07-16 22:26:48.005 1967 2305 I NativeVnc: 0) Received security type 2 07-16 22:26:48.005 1967 2305 I NativeVnc: Selecting security type 2 (0/1 in the list) 07-16 22:26:48.006 1967 2305 I NativeVnc: Selected Security Scheme 2 07-16 22:26:48.028 1967 2305 I NativeVnc: VNC authentication succeeded 07-16 22:26:48.032 1967 2305 I NativeVnc: Desktop name "Arch-Linux-ARM_tmoe-linux-vnc" 07-16 22:26:48.032 1967 2305 I NativeVnc: Connected to VNC server, using protocol version 3.8 07-16 22:26:48.032 1967 2305 I NativeVnc: VNC server default format: 07-16 22:26:48.032 1967 2305 I NativeVnc: 32 bits per pixel. 07-16 22:26:48.032 1967 2305 I NativeVnc: Least significant byte first in each pixel. 07-16 22:26:48.032 1967 2305 I NativeVnc: TRUE colour: max red 255 green 255 blue 255, shift red 16 green 8 blue 0 07-16 22:26:48.058 1967 2305 I NativeVnc: rfbClientProcessExtServerCutText. default cap. 07-16 22:26:48.370 1967 2306 D ShaderCompiler: Success. 07-16 22:26:48.371 1967 2306 D ShaderCompiler: Success. 07-16 22:26:48.511 1967 1985 D OpenGLRenderer: endAllStagingAnimators on 0x557cad91b0 (MaterialCardView) with handle 0x557cc9f840 07-16 22:26:49.665 1967 1967 D AndroidRuntime: Shutting down VM --------- beginning of crash 07-16 22:26:49.666 1967 1967 E AndroidRuntime: FATAL EXCEPTION: main 07-16 22:26:49.666 1967 1967 E AndroidRuntime: Process: com.gaurav.avnc, PID: 1967 07-16 22:26:49.666 1967 1967 E AndroidRuntime: java.lang.NullPointerException: Attempt to get length of null array 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.animation.ObjectAnimator.initAnimation(ObjectAnimator.java:875) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.animation.ValueAnimator.startAnimation(ValueAnimator.java:1263) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.animation.ValueAnimator.-wrap1(ValueAnimator.java) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.animation.ValueAnimator$AnimationHandler.doAnimationFrame(ValueAnimator.java:744) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.animation.ValueAnimator$AnimationHandler$1.run(ValueAnimator.java:801) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.view.Choreographer$CallbackRecord.run(Choreographer.java:858) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.view.Choreographer.doCallbacks(Choreographer.java:670) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.view.Choreographer.doFrame(Choreographer.java:603) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:844) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.os.Handler.handleCallback(Handler.java:743) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:95) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5426) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:772) 07-16 22:26:49.666 1967 1967 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:662) 07-16 22:26:51.459 1967 1967 I Process : Sending signal. PID: 1967 SIG: 9 07-16 22:26:51.603 2316 2327 I DualScreen: ApplicationThreadNative->scheduleLaunchActivity->taskId:17 07-16 22:26:51.701 2316 2316 D AppCompatDelegate: Checking for metadata for AppLocalesMetadataHolderService : Service not found 07-16 22:26:52.068 2316 2316 W art : Long monitor contention event with owner method=java.lang.Object dalvik.system.VMRuntime.newUnpaddedArray!(java.lang.Class, int) from VMRuntime.java:4294967294 waiters=0 for 207ms 07-16 22:26:52.093 2316 2316 W DualScreen: Previously focused view reported id 2131296731 during save, but can't be found during restore. 07-16 22:26:52.105 2316 2334 D OpenGLRenderer: Use EGL_SWAP_BEHAVIOR_PRESERVED: true 07-16 22:26:52.112 2316 2316 I com.gaurav.avnc: type=1400 audit(0.0:103): avc: denied { open } for path="/dev/dri/card0" dev="tmpfs" ino=6310 scontext=u:r:untrusted_app:s0:c512,c768 tcontext=u:object_r:device:s0 tclass=chr_file permissive=1 07-16 22:26:52.204 2316 2334 I OpenGLRenderer: Initialized EGL, version 1.4 07-16 22:26:53.036 2316 2316 W PathParser: Points are too far apart 4.000001792059637 07-16 22:26:53.036 2316 2316 W PathParser: Points are too far apart 4.000001792059637 07-16 22:26:53.036 2316 2316 W PathParser: Points are too far apart 4.000001792059637 07-16 22:26:53.036 2316 2316 W PathParser: Points are too far apart 4.000001792059637 07-16 22:26:54.207 2316 2327 I DualScreen: ApplicationThreadNative->scheduleLaunchActivity->taskId:17 07-16 22:26:54.475 2316 2334 D OpenGLRenderer: endAllStagingAnimators on 0x557cad3d80 (NavigationMenuItemView) with handle 0x557cd777c0 07-16 22:26:56.991 2316 2328 I DualScreen: ApplicationThreadNative->scheduleLaunchActivity->taskId:17 07-16 22:26:57.276 2316 2334 D OpenGLRenderer: endAllStagingAnimators on 0x557caec6d0 (NavigationMenuItemView) with handle 0x557cd9aea0 ```

Does anyone know how to fix it? (Selinux is set to Permissive status) (I have the device rooted. So any methods which need root accesses are welcomed)

gujjwal00 commented 2 months ago

Hi @fish4terrisa-MSDSM, which version are you using? v2.5.2 was released yesterday with fix for this issue.

fish4terrisa-MSDSM commented 2 months ago

Thank you! I have already tried it and it really worked! I'm using an older release.