diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2015-12-01 23:08:40 +0100 |
---|---|---|
committer | Konstantin Käfer <mail@kkaefer.com> | 2015-12-03 15:38:36 +0100 |
commit | c279fb171700c464c1cdac5cd2da39f142274d8d (patch) | |
tree | 1cd300b174ba13df6869b3c8bd591f07f0d66582 /src/mbgl/util/thread_local.hpp | |
parent | 0c351eb523d80fa534bd239b6d5e677e3d5635bb (diff) | |
download | qtlocation-mapboxgl-c279fb171700c464c1cdac5cd2da39f142274d8d.tar.gz |
[core] throw values, catch references
Diffstat (limited to 'src/mbgl/util/thread_local.hpp')
-rw-r--r-- | src/mbgl/util/thread_local.hpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mbgl/util/thread_local.hpp b/src/mbgl/util/thread_local.hpp index c805735cc4..5405037358 100644 --- a/src/mbgl/util/thread_local.hpp +++ b/src/mbgl/util/thread_local.hpp @@ -24,13 +24,13 @@ public: }); if (ret) { - throw new std::runtime_error("Failed to init local storage key."); + throw std::runtime_error("Failed to init local storage key."); } } inline ~ThreadLocal() { if (pthread_key_delete(key)) { - throw new std::runtime_error("Failed to delete local storage key."); + throw std::runtime_error("Failed to delete local storage key."); } } @@ -45,7 +45,7 @@ public: inline void set(T* ptr) { if (pthread_setspecific(key, ptr)) { - throw new std::runtime_error("Failed to set local storage."); + throw std::runtime_error("Failed to set local storage."); } } |