aboutsummaryrefslogtreecommitdiff
path: root/contrib/epee/include
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2018-12-04 17:07:51 +0200
committerRiccardo Spagni <ric@spagni.net>2018-12-04 17:07:51 +0200
commit398f7076bb67d749d76a1b275e5bd771e9714b4b (patch)
tree792b06ae57ec00c1b5d704655a7d81cf7fbe7064 /contrib/epee/include
parentMerge pull request #4850 (diff)
parentvarious: do not propagate exception through dtor (diff)
downloadmonero-398f7076bb67d749d76a1b275e5bd771e9714b4b.tar.xz
Merge pull request #4853
2b3595d0 various: do not propagate exception through dtor (moneromooo-monero)
Diffstat (limited to 'contrib/epee/include')
-rw-r--r--contrib/epee/include/mlocker.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/epee/include/mlocker.h b/contrib/epee/include/mlocker.h
index d2fc2ed58..a6d94b3d2 100644
--- a/contrib/epee/include/mlocker.h
+++ b/contrib/epee/include/mlocker.h
@@ -73,7 +73,7 @@ namespace epee
mlocked(const T &&t): T(t) { mlocker::lock(this, sizeof(T)); }
mlocked(const mlocked<T> &&mt): T(mt) { mlocker::lock(this, sizeof(T)); }
mlocked<T> &operator=(const mlocked<T> &mt) { T::operator=(mt); return *this; }
- ~mlocked() { mlocker::unlock(this, sizeof(T)); }
+ ~mlocked() { try { mlocker::unlock(this, sizeof(T)); } catch (...) { /* do not propagate */ } }
};
template<typename T>