From 1468ff13e338bec04b466cb95a28816a3852e487 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20K=C3=A4fer?= Date: Wed, 4 Nov 2015 12:57:50 +0100 Subject: [core] catch compression/decompression errors and report them --- platform/default/sqlite_cache.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/platform/default/sqlite_cache.cpp b/platform/default/sqlite_cache.cpp index d8b79c8f9b..5dc1521680 100644 --- a/platform/default/sqlite_cache.cpp +++ b/platform/default/sqlite_cache.cpp @@ -133,6 +133,9 @@ void SQLiteCache::Impl::get(const Resource &resource, Callback callback) { } catch (mapbox::sqlite::Exception& ex) { Log::Error(Event::Database, ex.code, ex.what()); callback(nullptr); + } catch (std::runtime_error& ex) { + Log::Error(Event::Database, ex.what()); + callback(nullptr); } } @@ -200,6 +203,8 @@ void SQLiteCache::Impl::put(const Resource& resource, std::shared_ptrrun(); } catch (mapbox::sqlite::Exception& ex) { Log::Error(Event::Database, ex.code, ex.what()); + } catch (std::runtime_error& ex) { + Log::Error(Event::Database, ex.what()); } } -- cgit v1.2.1