Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash on iOS when using mbtiles data source #2176

Open
rwrx opened this issue Jul 8, 2020 · 4 comments
Open

Crash on iOS when using mbtiles data source #2176

rwrx opened this issue Jul 8, 2020 · 4 comments
Assignees

Comments

@rwrx
Copy link
Contributor

rwrx commented Jul 8, 2020

Hello, on iOS when using mbtiles data source, I am getting this crash:

Crashed: Thread #1
EXC_BAD_ACCESS KERN_INVALID_ADDRESS 0x0000000111d09a10

Crashed: Thread
0  libz.1.dylib                   0x1d17407bc gzclose_w + 1300
1  libz.1.dylib                   0x1d174092c gzclose_w + 1668
2  TangramMap                     0x103831198 Tangram::zlib::inflate(char const*, unsigned long, std::__1::vector<char, std::__1::allocator<char> >&) + 4382757272
3  TangramMap                     0x103749dc8 Tangram::MBTilesDataSource::getTileData(Tangram::TileID const&, std::__1::vector<char, std::__1::allocator<char> >&) + 4381810120
4  TangramMap                     0x10374b8dc std::__1::__function::__func<Tangram::MBTilesDataSource::loadTileData(std::__1::shared_ptr<Tangram::TileTask>, Tangram::TileTaskCb)::$_0, std::__1::allocator<Tangram::MBTilesDataSource::loadTileData(std::__1::shared_ptr<Tangram::TileTask>, Tangram::TileTaskCb)::$_0>, void ()>::operator()() + 4381817052
5  TangramMap                     0x10374b0d4 Tangram::AsyncWorker::run() + 4381814996
6  TangramMap                     0x10374b3c4 void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void (Tangram::AsyncWorker::*)(), Tangram::AsyncWorker*> >(void*) + 4381815748
7  libsystem_pthread.dylib        0x19b09fd98 _pthread_start + 156
8  libsystem_pthread.dylib        0x19b0a374c thread_start + 8

On Android, I have never seen this kind of crash. What could be wrong? Thank you.

@warpedgeoid
Copy link

We saw a similar crash on occasion when loading a scene with an mbtiles data source. We switched to a individual tile files in a directory structure as a workaround.

@rwrx
Copy link
Contributor Author

rwrx commented Dec 28, 2020

@warpedgeoid thank you a lot for your suggestion, however in our use case we need to use mbtiles as a data source.

@matteblair
Copy link
Member

Apologies for not addressing this sooner! @rwrx can you share a sample mbtiles file that produces this crash?

@rwrx
Copy link
Contributor Author

rwrx commented Dec 29, 2020

@matteblair thank you. It is ok, I was also very busy. I have seen this crash directly on device - iPhone 8, but after very long time, it is happening very occasionally, but it is happening, here are some mbtiles for Slovakia country (there is vector, normal and contours data):

https://io.vecturagames.com/offline-maps/vector/slovakia_85633769_z14.mbtiles
https://io.vecturagames.com/offline-maps/normal/slovakia_85633769_z10.mbtiles
https://io.vecturagames.com/offline-maps/contours/slovakia_85633769_z13.mbtiles

Also I am using all of these pull requests in built Tangram-ES library:

#2185
#2111
#2120
#2142

@matteblair matteblair self-assigned this Dec 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants