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

Crash in VectorTileData destructor. #819

Closed
mb12 opened this issue Feb 5, 2015 · 2 comments
Closed

Crash in VectorTileData destructor. #819

mb12 opened this issue Feb 5, 2015 · 2 comments

Comments

@mb12
Copy link

mb12 commented Feb 5, 2015

I saw the following crash in VectorTileData destructor several times today.
I tried narrowing it down by enabling Guard Malloc, Scribble etc. in xcode. But I was unsuccessful. Enabling it was causing an std::bad_alloc crash due to a different issue.

* thread #25: tid = 0x4e8118, 0x3c7b0638 libc++abi.dylib`vtable for __cxxabiv1::__si_class_type_info + 8, name = 'Map', stop reason = EXC_BAD_ACCESS (code=2, address=0x3c7b0638)
    frame #0: 0x3c7b0638 libc++abi.dylib`vtable for __cxxabiv1::__si_class_type_info + 8
    frame #1: 0x003bb84a testapp`std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >::~pair() [inlined] std::__1::default_delete<mbgl::Bucket>::operator(this=0x16760b74, this=0x16760b74, __ptr=0x14620060)(mbgl::Bucket*) const + 130 at memory:2426
    frame #2: 0x003bb83a testapp`std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >::~pair() [inlined] std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> >::reset(this=0x16760b74, __p=0x00000000) + 56 at memory:2625
    frame #3: 0x003bb802 testapp`std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >::~pair() [inlined] std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> >::~unique_ptr(this=0x16760b74) at memory:2593
    frame #4: 0x003bb802 testapp`std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >::~pair() [inlined] std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> >::~unique_ptr(this=0x16760b74) at memory:2593
    frame #5: 0x003bb802 testapp`std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >::~pair(this=0x16760b68) + 58 at utility:248
    frame #6: 0x003bb7a8 testapp`std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >::~pair(this=0x16760b68) + 32 at utility:248
    frame #7: 0x003bb742 testapp`std::__1::__hash_table<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::__unordered_map_hasher<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::__unordered_map_equal<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::allocator<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > > >::__deallocate(std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, void*>*) [inlined] std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >::~__hash_value_type(this=0x16760b68) + 4 at unordered_map:563
    frame #8: 0x003bb73e testapp`std::__1::__hash_table<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::__unordered_map_hasher<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::__unordered_map_equal<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::allocator<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > > >::__deallocate(std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, void*>*) [inlined] std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >::~__hash_value_type(this=0x16760b68) at unordered_map:563
    frame #9: 0x003bb73e testapp`std::__1::__hash_table<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::__unordered_map_hasher<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::__unordered_map_equal<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::allocator<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > > >::__deallocate(std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, void*>*) [inlined] void std::__1::allocator_traits<std::__1::allocator<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, void*> > >::__destroy<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > >((null)=std::__1::false_type at 0x03b96350, (null)=0x14635da4, __p=0x16760b68) + 10 at memory:1585
    frame #10: 0x003bb734 testapp`std::__1::__hash_table<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::__unordered_map_hasher<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::__unordered_map_equal<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::allocator<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > > >::__deallocate(std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, void*>*) [inlined] void std::__1::allocator_traits<std::__1::allocator<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, void*> > >::destroy<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > >(__a=0x14635da4, __p=0x16760b68) + 8 at memory:1483
    frame #11: 0x003bb72c testapp`std::__1::__hash_table<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::__unordered_map_hasher<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::__unordered_map_equal<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::allocator<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > > >::__deallocate(this=0x14635d9c, __np=0x16760b60) + 76 at __hash_table:1347
    frame #12: 0x003bb646 testapp`std::__1::__hash_table<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::__unordered_map_hasher<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::__unordered_map_equal<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::allocator<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > > >::~__hash_table(this=0x14635d9c) + 46 at __hash_table:1287
    frame #13: 0x003bb5f8 testapp`std::__1::__hash_table<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::__unordered_map_hasher<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::__unordered_map_equal<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, true>, std::__1::allocator<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > > >::~__hash_table(this=0x14635d9c) + 32 at __hash_table:1286
    frame #14: 0x003bb5b8 testapp`std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > > >::~unordered_map(this=0x14635d9c) + 32 at unordered_map:711
    frame #15: 0x003b9fe0 testapp`std::__1::unordered_map<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> >, std::__1::hash<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::equal_to<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, std::__1::unique_ptr<mbgl::Bucket, std::__1::default_delete<mbgl::Bucket> > > > >::~unordered_map(this=0x14635d9c) + 32 at unordered_map:711
  * frame #16: 0x003b9042 testapp`mbgl::VectorTileData::~VectorTileData(this=0x14635cbc) + 210 at vector_tile_data.cpp:33
    frame #17: 0x003b91ac testapp`mbgl::VectorTileData::~VectorTileData(this=0x14635cbc) + 32 at vector_tile_data.cpp:31
    frame #18: 0x00373134 testapp`std::__1::__shared_ptr_emplace<mbgl::VectorTileData, std::__1::allocator<mbgl::VectorTileData> >::__on_zero_shared(this=0x14635cb0) + 40 at memory:3735
    frame #19: 0x39bd7d84 libc++.1.dylib`std::__1::__shared_weak_count::__release_shared() + 52
    frame #20: 0x00361976 testapp`std::__1::shared_ptr<mbgl::TileData>::~shared_ptr(this=0x14639440) + 50 at memory:4448
    frame #21: 0x00361924 testapp`mbgl::util::ptr<mbgl::TileData>::~ptr(this=0x14639440) + 36 at ptr.hpp:11
    frame #22: 0x003618e0 testapp`mbgl::util::ptr<mbgl::TileData>::~ptr(this=0x14639440) + 32 at ptr.hpp:11
    frame #23: 0x00389232 testapp`uv::work<mbgl::util::ptr<mbgl::TileData> >::~work(this=0x14639440) + 62 at uv_detail.hpp:144
    frame #24: 0x003891d4 testapp`uv::work<mbgl::util::ptr<mbgl::TileData> >::~work(this=0x14639440) + 32 at uv_detail.hpp:144
    frame #25: 0x003890de testapp`uv::work<mbgl::util::ptr<mbgl::TileData> >::after_work(data=0x14639440) + 58 at uv_detail.hpp:166
    frame #26: 0x004ee65a testapp`uv__worker_after(ptr=0x14638d20) + 130 at uv-worker.c:56
    frame #27: 0x004ee348 testapp`uv__messenger_callback(async=0x146ce6cc, status=0) + 104 at uv-messenger.c:37
    frame #28: 0x002ef536 testapp`uv__async_event(loop=0x1467ed50, w=0x1467ee28, nevents=1) + 126 at async.c:80
    frame #29: 0x002ef7de testapp`uv__async_io(loop=0x1467ed50, w=0x1467ee2c, events=1) + 190 at async.c:156
    frame #30: 0x002f6eb4 testapp`uv__io_poll(loop=0x1467ed50, timeout=-1) + 2252 at kqueue.c:233
    frame #31: 0x002efc06 testapp`uv_run(loop=0x1467ed50, mode=UV_RUN_DEFAULT) + 130 at core.c:317
    frame #32: 0x00356c0e testapp`mbgl::Map::run(this=0x1467fa60) + 330 at map.cpp:244
    frame #33: 0x0035bea4 testapp`mbgl::Map::start(this=0x145a5710)::$_5::operator()() const + 192 at map.cpp:195
    frame #34: 0x0035bc9a testapp`void* std::__1::__thread_proxy<std::__1::tuple<mbgl::Map::start(__vp=0x145a5710)::$_5> >(void*) + 274 at memory:2602
    frame #35: 0x3a974918 libsystem_pthread.dylib`_pthread_body + 140
    frame #36: 0x3a97488a libsystem_pthread.dylib`_pthread_start + 102
@jfirebaugh
Copy link
Contributor

#1309.

@jfirebaugh
Copy link
Contributor

Oops wrong bug. Still, this is likely fixed or will be with #1065.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants