Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

MapboxMap.queryRenderedFeatures() crash with Proguard #7378

Closed

Description

@klblk

Platform: Android
Mapbox SDK version: 4.2.0 (tested beta4 and beta5)

Steps to trigger behavior

mapboxMap.setOnMapClickListener(new MapboxMap.OnMapClickListener() {
            @Override
            public void onMapClick(@NonNull LatLng point) {
                List<Feature> features = mapboxMap.queryRenderedFeatures(mapboxMap.getProjection().toScreenLocation(point), "my_layer_name");
                ...
            }
        });

Crash if features not empty.
It works without Proguard.

Log:

*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
Build fingerprint: 'google/shamu/shamu:7.0/NBD91P/3397968:user/release-keys'
Revision: '0'
ABI: 'arm'
pid: 18509, tid: 18509, name: my.package  >>> my.package <<<
signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
Abort message: '/usr/local/google/buildbot/src/android/ndk-r12-release/ndk/sources/cxx-stl/llvm-libc++abi/libcxxabi/src/abort_message.cpp:74: void abort_message(const char *, ...): assertion "terminating with uncaught exception of type jni::PendingJavaException" failed'
    r0 00000000  r1 0000484d  r2 00000006  r3 00000008
    r4 b040458c  r5 00000006  r6 b0404534  r7 0000010c
    r8 bedc2204  r9 bedc22b8  sl cccccccd  fp 00200029
    ip 0000000b  sp bedc1cf8  lr ada60517  pc ada62d80  cpsr 60070010

backtrace:
    #00 pc 00049d80  /system/lib/libc.so (tgkill+12)
    #01 pc 00047513  /system/lib/libc.so (pthread_kill+34)
    #02 pc 0001d615  /system/lib/libc.so (raise+10)
    #03 pc 00019161  /system/lib/libc.so (__libc_android_abort+34)
    #04 pc 00017028  /system/lib/libc.so (abort+4)
    #05 pc 0001b613  /system/lib/libc.so (__libc_fatal+22)
    #06 pc 0001935b  /system/lib/libc.so (__assert2+18)
    #07 pc 003d6bbf  /data/app/com.hubbmap-1/lib/arm/libmapbox-gl.so
    #08 pc 003d6ca7  /data/app/com.hubbmap-1/lib/arm/libmapbox-gl.so
    #09 pc 003d5291  /data/app/com.hubbmap-1/lib/arm/libmapbox-gl.so
    #10 pc 003d52f1  /data/app/com.hubbmap-1/lib/arm/libmapbox-gl.so (_ZSt9terminatev+44)
    #11 pc 000491bc  /data/app/com.hubbmap-1/lib/arm/libmapbox-gl.so

Activity

  1. added this to the android-v4.2.0 milestone on Dec 12, 2016
  2. added
    Android
    on Dec 12, 2016
  3. tobrun commented on Dec 12, 2016

    @tobrun
    Member

    Thank you for the report! This should be picked up before next release.
    cc @mapbox/android.

  4. tobrun commented on Dec 12, 2016

    @tobrun
    Member

    Was able to reproduce the crash and symbolicate it to:

    ********** Crash dump: **********
    Build fingerprint: 'google/sailfish/sailfish:7.1/NDE63V/3389651:user/release-keys'
    pid: 8914, tid: 8914, name: pboxsdk.testapp  >>> com.mapbox.mapboxsdk.testapp <<<
    signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
    Stack frame #00 pc 00049da0  /system/lib/libc.so (tgkill+12)
    Stack frame #01 pc 00047533  /system/lib/libc.so (pthread_kill+34)
    Stack frame #02 pc 0001d635  /system/lib/libc.so (raise+10)
    Stack frame #03 pc 00019181  /system/lib/libc.so (__libc_android_abort+34)
    Stack frame #04 pc 00017048  /system/lib/libc.so (abort+4)
    Stack frame #05 pc 0001b633  /system/lib/libc.so (__libc_fatal+22)
    Stack frame #06 pc 0001937b  /system/lib/libc.so (__assert2+18)
    Stack frame #07 pc 003f383f  /data/app/com.mapbox.mapboxsdk.testapp-1/lib/arm/libmapbox-gl.so: Routine abort_message at /usr/local/google/buildbot/src/android/ndk-r12-release/ndk/sources/cxx-stl/llvm-libc++abi/libcxxabi/src/abort_message.cpp:74
    Stack frame #08 pc 003f3927  /data/app/com.mapbox.mapboxsdk.testapp-1/lib/arm/libmapbox-gl.so: Routine default_terminate_handler() at /usr/local/google/buildbot/src/android/ndk-r12-release/ndk/sources/cxx-stl/llvm-libc++abi/libcxxabi/src/cxa_default_handlers.cpp:68
    Stack frame #09 pc 003f1f11  /data/app/com.mapbox.mapboxsdk.testapp-1/lib/arm/libmapbox-gl.so: Routine std::__terminate(void (*)()) at /usr/local/google/buildbot/src/android/ndk-r12-release/ndk/sources/cxx-stl/llvm-libc++abi/libcxxabi/src/cxa_handlers.cpp:68
    Stack frame #10 pc 003f1f71  /data/app/com.mapbox.mapboxsdk.testapp-1/lib/arm/libmapbox-gl.so (_ZSt9terminatev+44): Routine std::terminate() at /usr/local/google/buildbot/src/android/ndk-r12-release/ndk/sources/cxx-stl/llvm-libc++abi/libcxxabi/src/cxa_handlers.cpp:99
    Stack frame #11 pc 00049674  /data/app/com.mapbox.mapboxsdk.testapp-1/lib/arm/libmapbox-gl.so: Routine __clang_call_terminate at libgcc2.c:?
    
    
  5. cammace commented on Dec 12, 2016

    @cammace
    Contributor

    I've resolved this issue in #7389, seems to be an issue with obfuscation and JNI bindings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Android

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions