oNaiPs / droidVncServer

VNC server for Android devices.
GNU General Public License v3.0
906 stars 480 forks source link

Red hued screen / Crash on session close (Sony Ericsson Xperia Play) #17

Closed tr00st closed 12 years ago

tr00st commented 13 years ago

Slightly weird behaviour on this one - on connecting to the VNC server (TCP, forwarded over usb - adb forward tcp:5091 tcp:5091), the screen appears mostly red (green items appear to have the blue channel - possibly channels being swapped?)

Client output:

$ vncviewer localhost:5901
Connected to RFB server, using protocol version 3.8
No authentication needed
Authentication successful
Desktop name "Android"
VNC server default format:
  32 bits per pixel.
  Least significant byte first in each pixel.
  True colour: max red 255 green 255 blue 255, shift red 24 green 16 blue 8
Using default colormap which is TrueColor.  Pixel format:
  32 bits per pixel.
  Least significant byte first in each pixel.
  True colour: max red 255 green 255 blue 255, shift red 16 green 8 blue 0
Same machine: preferring raw encoding

To note, same behaviour occurs when running across the network, without the crash, and with slightly different client logs:

$ vncviewer 192.168.0.102:5901
Connected to RFB server, using protocol version 3.8
No authentication needed
Authentication successful
Desktop name "Android"
VNC server default format:
  32 bits per pixel.
  Least significant byte first in each pixel.
  True colour: max red 255 green 255 blue 255, shift red 24 green 16 blue 8
Using default colormap which is TrueColor.  Pixel format:
  32 bits per pixel.
  Least significant byte first in each pixel.
  True colour: max red 255 green 255 blue 255, shift red 16 green 8 blue 0

Logcat output follows:

D/dalvikvm(22863): GC_CONCURRENT freed 2115K, 68% free 2996K/9095K, external 9970K/11960K, paused 3ms+3ms
D/dalvikvm(22863): GC_FOR_MALLOC freed 2090K, 68% free 2949K/9095K, external 7466K/9323K, paused 17ms
D/dalvikvm(22863): GC_CONCURRENT freed 2053K, 68% free 2932K/9095K, external 5806K/7407K, paused 2ms+2ms
V/VNC     (22863): isAndroidServerRunning? no
V/VNC     (22863): Starting /data/data/org.onaips.vnc/files/androidvncserver  -r 0 -s 100 -P 5901 -t 0
D/su      (23143): 10177 org.onaips.vnc executing 0 /system/bin/sh using shell /system/bin/sh : sh
I/VNC     (23146): rotating to 0 degrees
I/VNC     (23146): scaling to 100 percent
I/VNC     (23146): In test mode! t=0
I/VNC     (23146): Initializing framebuffer device...
I/VNC     (23146): line_lenght=1920 xres=480, yres=854, xresv=480, yresv=1708, xoffs=0, yoffs=0, bpp=32
I/VNC     (23146): colourmap_rgb=24:16:8    lenght=8:8:8
I/VNC     (23146): Initializing virtual keyboard and touch device...
I/EventHub(  203): New keyboard: device->id=0x60008 devname='qwerty' propName='hw.keyboards.393224.devname' keylayout='/system/usr/keylayout/qwerty.kl'
I/EventHub(  203): New device: path=/dev/input/event12 name=qwerty id=0x60008 (of 0x9) index=9 fd=203 classes=0x27
D/kernel  (  115): [148943.541503] input: qwerty as /devices/virtual/input/input17
I/InputReader(  203): Device reconfigured: id=0x60008, name=qwerty, display size is now 479x853
I/InputReader(  203): Device added: id=0x60008, name=qwerty, sources=00001303
I/InputManager-Callbacks(  203): No input device calibration properties found for device qwerty.
I/InputManager-Callbacks(  203): No virtual keys found for device qwerty.
I/ActivityManager(  203): Config changed: { scale=1.0 imsi=234/20 loc=en_GB touch=3 keys=2/1/2 nav=2/1 orien=1 layout=34 uiMode=17 seq=156}
I/VNC     (23146): Initializing VNC server:
I/VNC     (23146):      width:  480
I/VNC     (23146):      height: 854
I/VNC     (23146):      bpp:    32
I/VNC     (23146):      port:   5901
I/VNC     (23146): Initializing server...
D/kernel  (  115): [148943.622222] keychord: using input dev qwerty for fevent
I/VNC     (23146): I'm on update_screen_32
D/GestureDetector(  538): touchSlop:32 doubleTapSlop:195
E/WindowManager(22863): Activity org.onaips.vnc.MainActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@2b02a6d0 that was originally added here
E/WindowManager(22863): android.view.WindowLeaked: Activity org.onaips.vnc.MainActivity has leaked window com.android.internal.policy.impl.PhoneWindow$DecorView@2b02a6d0 that was originally added here
E/WindowManager(22863):         at android.view.ViewRoot.<init>(ViewRoot.java:264)
E/WindowManager(22863):         at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:148)
E/WindowManager(22863):         at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:91)
E/WindowManager(22863):         at android.view.Window$LocalWindowManager.addView(Window.java:424)
E/WindowManager(22863):         at android.app.Dialog.show(Dialog.java:241)
E/WindowManager(22863):         at android.app.ProgressDialog.show(ProgressDialog.java:107)
E/WindowManager(22863):         at android.app.ProgressDialog.show(ProgressDialog.java:90)
E/WindowManager(22863):         at org.onaips.vnc.MainActivity.prepareWatchdog(MainActivity.java:338)
E/WindowManager(22863):         at org.onaips.vnc.MainActivity.startServerButtonClicked(MainActivity.java:468)
E/WindowManager(22863):         at org.onaips.vnc.MainActivity$4.onClick(MainActivity.java:188)
E/WindowManager(22863):         at android.view.View.performClick(View.java:2534)
E/WindowManager(22863):         at android.view.View$PerformClick.run(View.java:9210)
E/WindowManager(22863):         at android.os.Handler.handleCallback(Handler.java:587)
E/WindowManager(22863):         at android.os.Handler.dispatchMessage(Handler.java:92)
E/WindowManager(22863):         at android.os.Looper.loop(Looper.java:123)
E/WindowManager(22863):         at android.app.ActivityThread.main(ActivityThread.java:3652)
E/WindowManager(22863):         at java.lang.reflect.Method.invokeNative(Native Method)
E/WindowManager(22863):         at java.lang.reflect.Method.invoke(Method.java:507)
E/WindowManager(22863):         at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:862)
E/WindowManager(22863):         at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:620)
E/WindowManager(22863):         at dalvik.system.NativeStart.main(Native Method)
D/dalvikvm(22863): GC_EXTERNAL_ALLOC freed 1856K, 69% free 2887K/9095K, external 6212K/7407K, paused 57ms
I/CustomizationProvider(22083): No configuration file: /system/etc/customization/settings/com/sonyericsson/textinput/uxp/custom_settings.xml
D/dalvikvm(  538): GC_EXTERNAL_ALLOC freed 275K, 61% free 2968K/7495K, external 2907K/2925K, paused 52ms
W/Resources(22863): Converting to string: TypedValue{t=0x12/d=0x0 a=3 r=0x7f090002}
W/Resources(22863): Converting to string: TypedValue{t=0x12/d=0x0 a=3 r=0x7f090004}
E/org.onaips.vnc.MainActivity$SocketListener(22863): Address already in use
D/dalvikvm(22863): GC_CONCURRENT freed 2012K, 68% free 2963K/9095K, external 7869K/9757K, paused 2ms+2ms
D/dalvikvm(22863): GC_CONCURRENT freed 2019K, 68% free 2981K/9095K, external 7869K/9757K, paused 2ms+2ms
V/VNC     (22863): isAndroidServerRunning? yes
D/dalvikvm(22863): GC_CONCURRENT freed 2020K, 67% free 3004K/9095K, external 7869K/9757K, paused 3ms+3ms
D/dalvikvm(22863): GC_CONCURRENT freed 1876K, 66% free 3164K/9095K, external 7872K/9757K, paused 1ms+2ms
D/dalvikvm(22863): GC_CONCURRENT freed 2190K, 67% free 3013K/9095K, external 7872K/9757K, paused 2ms+2ms
D/dalvikvm(22863): GC_CONCURRENT freed 2017K, 67% free 3036K/9095K, external 7872K/9757K, paused 1ms+2ms
V/VNC     (22863): isAndroidServerRunning? yes
I/CustomizationProvider(22083): No configuration file: /system/etc/customization/settings/com/sonyericsson/textinput/uxp/custom_settings.xml
V/VNC     (22863): ~CONNE
D/lights  (  203): set_light_attention: color=0x00ffffff, mode=2
D/lights  (  203): set_light_attention: color=0x00000000, mode=0
D/dalvikvm(  203): GC_EXPLICIT freed 71K, 41% free 7587K/12743K, external 4503K/5623K, paused 106ms
D/dalvikvm(22863): GC_CONCURRENT freed 1925K, 66% free 3150K/9095K, external 7872K/9757K, paused 2ms+2ms
D/dalvikvm(22863): GC_CONCURRENT freed 2183K, 67% free 3006K/9095K, external 7872K/9757K, paused 2ms+2ms
D/dalvikvm(22863): GC_CONCURRENT freed 2019K, 67% free 3021K/9095K, external 7872K/9757K, paused 2ms+2ms
V/VNC     (22863): isAndroidServerRunning? yes
V/VNC     (22863): ~DISCO
I/DEBUG   ( 9028): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
I/DEBUG   ( 9028): Build fingerprint: 'SEMC/R800i_1247-6199/R800i:2.3.2/3.0.A.2.181/SvfP:user/release-keys'
I/DEBUG   ( 9028): pid: 23146, tid: 23146  >>> /data/data/org.onaips.vnc/files/androidvncserver <<<
I/DEBUG   ( 9028): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr deadbaad
I/DEBUG   ( 9028):  r0 00000027  r1 deadbaad  r2 80000000  r3 00000000
I/DEBUG   ( 9028):  r4 00000001  r5 00000000  r6 00067ad8  r7 0005c000
I/DEBUG   ( 9028):  r8 000007fc  r9 00000230  10 0005c008  fp 00007741
I/DEBUG   ( 9028):  ip 6fd46688  sp 7ea52ae0  lr 6fd1926d  pc 6fd15d00  cpsr 60000030
I/DEBUG   ( 9028):  d0  6472656767756265  d1  006f746e6f726f67
I/DEBUG   ( 9028):  d2  000000000000006f  d3  000000000000006e
I/DEBUG   ( 9028):  d4  0000000000000000  d5  0000000000000000
I/DEBUG   ( 9028):  d6  0000000000000000  d7  00a8c00000000000
I/DEBUG   ( 9028):  d8  0000000000000000  d9  0000000000000000
I/DEBUG   ( 9028):  d10 0000000000000000  d11 0000000000000000
I/DEBUG   ( 9028):  d12 0000000000000000  d13 0000000000000000
I/DEBUG   ( 9028):  d14 0000000000000000  d15 0000000000000000
I/DEBUG   ( 9028):  d16 4165180010000000  d17 3fe0000000000000
I/DEBUG   ( 9028):  d18 0000000000000000  d19 0000000000000000
I/DEBUG   ( 9028):  d20 0000000000000000  d21 0000000000000000
I/DEBUG   ( 9028):  d22 0000000000000000  d23 0000000000000000
I/DEBUG   ( 9028):  d24 0000000000000000  d25 0000000000000000
I/DEBUG   ( 9028):  d26 0000000000000000  d27 0000000000000000
I/DEBUG   ( 9028):  d28 0000000000000000  d29 0000000000000000
I/DEBUG   ( 9028):  d30 0000000000000000  d31 0000000000000000
I/DEBUG   ( 9028):  scr 00000010
I/DEBUG   ( 9028):
I/DEBUG   ( 9028):          #00  pc 00015d00  /system/lib/libc.so
I/DEBUG   ( 9028):          #01  pc 00013658  /system/lib/libc.so
I/DEBUG   ( 9028):          #02  pc 00014536  /system/lib/libc.so
I/DEBUG   ( 9028):          #03  pc 000121ee  /data/data/org.onaips.vnc/files/androidvncserver
I/DEBUG   ( 9028):          #04  pc 000121f6  /data/data/org.onaips.vnc/files/androidvncserver
I/DEBUG   ( 9028):          #05  pc 00011afc  /data/data/org.onaips.vnc/files/androidvncserver
I/DEBUG   ( 9028):          #06  pc 0000d46a  /data/data/org.onaips.vnc/files/androidvncserver
I/DEBUG   ( 9028):          #07  pc 0000bbf0  /data/data/org.onaips.vnc/files/androidvncserver
I/DEBUG   ( 9028):          #08  pc 00014bae  /system/lib/libc.so
I/DEBUG   ( 9028):
I/DEBUG   ( 9028): code around pc:
I/DEBUG   ( 9028): 6fd15ce0 2c006824 e028d1fb b13368db c064f8df
I/DEBUG   ( 9028): 6fd15cf0 44fc2401 4000f8cc 49124798 25002027
I/DEBUG   ( 9028): 6fd15d00 f7f57008 2106ec56 edb2f7f6 460aa901
I/DEBUG   ( 9028): 6fd15d10 f04f2006 95015380 95029303 e918f7f6
I/DEBUG   ( 9028): 6fd15d20 462aa905 f7f62002 f7f5e924 2106ec42
I/DEBUG   ( 9028):
I/DEBUG   ( 9028): code around lr:
I/DEBUG   ( 9028): 6fd1924c 4a0e4b0d e92d447b 589c41f0 26004680
I/DEBUG   ( 9028): 6fd1925c 686768a5 f9b5e006 b113300c 47c04628
I/DEBUG   ( 9028): 6fd1926c 35544306 37fff117 6824d5f5 d1ef2c00
I/DEBUG   ( 9028): 6fd1927c e8bd4630 bf0081f0 000282d0 ffffff88
I/DEBUG   ( 9028): 6fd1928c b086b570 f602fb01 9004460c a804a901
I/DEBUG   ( 9028):
I/DEBUG   ( 9028): stack:
I/DEBUG   ( 9028):     7ea52aa0  00000000
I/DEBUG   ( 9028):     7ea52aa4  6f000001
I/DEBUG   ( 9028):     7ea52aa8  6f2e6772
I/DEBUG   ( 9028):     7ea52aac  7069616e
I/DEBUG   ( 9028):     7ea52ab0  6fd4272c  /system/lib/libc.so
I/DEBUG   ( 9028):     7ea52ab4  6fd426d8  /system/lib/libc.so
I/DEBUG   ( 9028):     7ea52ab8  00000000
I/DEBUG   ( 9028):     7ea52abc  6fd1926d  /system/lib/libc.so
I/DEBUG   ( 9028):     7ea52ac0  00000001
I/DEBUG   ( 9028):     7ea52ac4  7ea52af4
I/DEBUG   ( 9028):     7ea52ac8  00067ad8  [heap]
I/DEBUG   ( 9028):     7ea52acc  0005c000  [heap]
I/DEBUG   ( 9028):     7ea52ad0  000007fc
I/DEBUG   ( 9028):     7ea52ad4  6fd1856f  /system/lib/libc.so
I/DEBUG   ( 9028):     7ea52ad8  df002777
I/DEBUG   ( 9028):     7ea52adc  e3a070ad
I/DEBUG   ( 9028): #00 7ea52ae0  20000204
I/DEBUG   ( 9028):     7ea52ae4  00000001
I/DEBUG   ( 9028):     7ea52ae8  00067ad8  [heap]
I/DEBUG   ( 9028):     7ea52aec  00067aec  [heap]
I/DEBUG   ( 9028):     7ea52af0  00067ad8  [heap]
I/DEBUG   ( 9028):     7ea52af4  fffffbdf
I/DEBUG   ( 9028):     7ea52af8  000007fc
I/DEBUG   ( 9028):     7ea52afc  6fd46470
I/DEBUG   ( 9028):     7ea52b00  00067aec  [heap]
I/DEBUG   ( 9028):     7ea52b04  6fd1365d  /system/lib/libc.so
I/DEBUG   ( 9028): #01 7ea52b08  00067ad8  [heap]
I/DEBUG   ( 9028):     7ea52b0c  00067aec  [heap]
I/DEBUG   ( 9028):     7ea52b10  0003c4ac  /data/data/org.onaips.vnc/files/androidvncserver
I/DEBUG   ( 9028):     7ea52b14  0005c008  [heap]
I/DEBUG   ( 9028):     7ea52b18  000007fc
I/DEBUG   ( 9028):     7ea52b1c  6fd14539  /system/lib/libc.so
I/BootReceiver(  203): Copying /data/tombstones/tombstone_07 to DropBox (SYSTEM_TOMBSTONE)
I/EventHub(  203): Removed device: path=/dev/input/event12 name=qwerty id=0x60008 (of 0x9) index=10 fd=203 classes=0x27
I/InputReader(  203): Device removed: id=0x60008, name=qwerty, sources=00001303
I/ActivityManager(  203): Config changed: { scale=1.0 imsi=234/20 loc=en_GB touch=3 keys=1/1/2 nav=2/1 orien=1 layout=34 uiMode=17 seq=157}
D/GestureDetector(  538): touchSlop:32 doubleTapSlop:195
I/CustomizationProvider(22083): No configuration file: /system/etc/customization/settings/com/sonyericsson/textinput/uxp/custom_settings.xml
W/Resources(22863): Converting to string: TypedValue{t=0x12/d=0x0 a=3 r=0x7f090002}
W/Resources(22863): Converting to string: TypedValue{t=0x12/d=0x0 a=3 r=0x7f090004}
E/org.onaips.vnc.MainActivity$SocketListener(22863): Address already in use
D/dalvikvm(22634): GC_CONCURRENT freed 1355K, 59% free 2846K/6791K, external 1685K/2133K, paused 14ms+4ms
D/dalvikvm(22863): GC_CONCURRENT freed 2067K, 68% free 2998K/9095K, external 9529K/9757K, paused 1ms+2ms
D/dalvikvm(22863): GC_CONCURRENT freed 2077K, 68% free 2959K/9095K, external 7463K/9320K, paused 2ms+2ms
D/dalvikvm(22863): GC_CONCURRENT freed 1999K, 68% free 2981K/9095K, external 7463K/9320K, paused 2ms+2ms
V/VNC     (22863): isAndroidServerRunning? no
D/dalvikvm(22863): GC_CONCURRENT freed 1899K, 66% free 3127K/9095K, external 7466K/9320K, paused 2ms+2ms
D/dalvikvm(22863): GC_CONCURRENT freed 2201K, 68% free 2967K/9095K, external 7466K/9320K, paused 2ms+1ms
D/dalvikvm(22863): GC_CONCURRENT freed 2032K, 68% free 2973K/9095K, external 7466K/9320K, paused 2ms+2ms
V/VNC     (22863): isAndroidServerRunning? no
I/CustomizationProvider(22083): No configuration file: /system/etc/customization/settings/com/sonyericsson/textinput/uxp/custom_settings.xml
tr00st commented 13 years ago

Added screenshot at https://tr00st.co.uk/pics/red_vnc.png

andr2000 commented 13 years ago

VNC server 0.991, Samsung/GT-I5800: right after the connection session is closed and there is a SIGSEGV:

V/VNC ( 2628): isAndroidServerRunning? yes V/VNC ( 2628): ~CONNE V/VNC ( 2628): ~DISCO I/DEBUG ( 2172): * * * * * * * * * * * * * * * * I/DEBUG ( 2172): Build fingerprint: 'samsung/GT-I5800/GT-I5800/GT-I5800:2.2/FROYO/XWJPE:user/release-keys' I/DEBUG ( 2172): pid: 3086, tid: 3086 >>> /data/data/org.onaips.vnc/files/androidvncserver <<< I/DEBUG ( 2172): signal 11 (SIGSEGV), fault addr 00000000 I/DEBUG ( 2172): r0 ffffffff r1 000000ff r2 000001d0 r3 00000000 I/DEBUG ( 2172): r4 0003c4ac r5 0003cbe4 r6 0003cc64 r7 00000238 I/DEBUG ( 2172): r8 000001d0 r9 000001a4 10 000001f8 fp 00000738 I/DEBUG ( 2172): ip 00000003 sp be95cc58 lr 0000bbf9 pc 00000000 cpsr 80000010 I/DEBUG ( 2172): #00 pc 00000000 I/DEBUG ( 2172): #01 pc 0000bbf6 /data/data/org.onaips.vnc/files/androidvncserver I/DEBUG ( 2172): #02 pc 0000d4da /system/lib/libc.so I/DEBUG ( 2172): I/DEBUG ( 2172): code around pc: I/DEBUG ( 2172): I/DEBUG ( 2172): code around lr: I/DEBUG ( 2172): 0000bbd8 f0022200 4641f84d 681b5863 dc352b28 I/DEBUG ( 2172): 0000bbe8 dd2d2b1e 494b6b68 fb8ef001 47986873 I/DEBUG ( 2172): 0000bbf8 58a34652 2b00681b 4640d01e 46495823 I/DEBUG ( 2172): 0000bc08 681a6b68 601a3201 22005863 59c3601a I/DEBUG ( 2172): 0000bc18 d1d92b00 f0014940 e7d1fb77 f7ff1c30

oNaiPs commented 12 years ago

should be working in next release.