Re: SIGSEGV when finishing "native-activity" sample

597 views
Skip to first unread message

Andrew Hsieh

unread,
Aug 10, 2012, 9:47:59 PM8/10/12
to andro...@googlegroups.com
What API level is your emulator running?  Alternatively, could you run "adb -e bugreport > log" and attach the log?

On Sat, Aug 11, 2012 at 7:29 AM, Allan Hasegawa <sir...@gmail.com> wrote:
Hey everyone,

I'm getting a segmentation error when I press the "back button" while running the "native-activity" sample in landscape mode. No code were changed. If I execute the same code/apk in portrait mode, everything works just fine.

The segmentation error happens when the code is executed on the Android Emulator. If I execute it on a Galaxy Note, no segmentation faults happens, but error messages shows up in the logcat. I attached the logcat dump and the nice "ndk-stack" generated with the emulator to this e-mail. The logcat messages when I execute with a Galaxy Note are:

E/SurfaceTexture( 1705): query: SurfaceTexture has been abandoned!
E/SurfaceTexture( 1705): queueBuffer: SurfaceTexture has been abandoned!
E/SurfaceTextureClient(31566): queueBuffer: error queuing buffer to SurfaceTexture, -19
E/MaliEGL (31566): void __egl_platform_queue_buffer(mali_base_ctx_type*, egl_buffer*):849 [EGL-ERROR] unable to queue buffer (0xdcd7c)


The problem is that with the seg fault, part of the code are not executed when closing the app. So, can this be a problem?

Ps.: I'm using the android-ndk-r8b.
Ps2.: To change between landscape/portrait mode I am pressing the key "7" on the numpad.

--
You received this message because you are subscribed to the Google Groups "android-ndk" group.
To view this discussion on the web visit https://groups.google.com/d/msg/android-ndk/-/_fgWYrzeHsAJ.
To post to this group, send email to andro...@googlegroups.com.
To unsubscribe from this group, send email to android-ndk...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/android-ndk?hl=en.

Andrew Hsieh

unread,
Aug 11, 2012, 10:23:19 PM8/11/12
to andro...@googlegroups.com
It looks like a platform bug fixed in very recent 4.1 image.  I see SIGSEGV you mentioned in API16 image from SDK when running native-activity in landscape mode.  The problem doesn't exit running from arm image rebuilt from AOSP 2 days ago.  It quits w/o error when hitting "back" in landscape mode on my Galaxy Nexus running ICS.
Question:  is your Galaxy Note running 4.1 image? 

On Sat, Aug 11, 2012 at 10:23 AM, Allan Hasegawa <sir...@gmail.com> wrote:
I was using the "Android 4.1 - API Level 16" image before.

I just ran the same code with the "Android 2.3.3 - API Level 10" emulator and the SIGSEGV did not happen, it worked as expected.
To view this discussion on the web visit https://groups.google.com/d/msg/android-ndk/-/9I7cQf1LsyEJ.

Allan Hasegawa

unread,
Aug 11, 2012, 10:39:30 PM8/11/12
to andro...@googlegroups.com
oh Thank you for taking a look at this issue, and it is very nice to see it was fixed.

The Galaxy Note is running the Android 4.0.3. It is running the stock image, no root, but, other than the error messages in the logcat, no other issues happens. I can send the app to the background and return without a problem. When destroying it, the error message do not prevent the entire code from executing, like the segmentation fault in the emulator.
Att.,
Allan Yoshio Hasegawa...

Reply all
Reply to author
Forward
0 new messages