projects
/
dcpomatic.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Make reset() safer if the new throws.
[dcpomatic.git]
/
src
/
wx
/
wx_ptr.h
diff --git
a/src/wx/wx_ptr.h
b/src/wx/wx_ptr.h
index 24bccb0438a517b59a9c9a8b4d70c9149a87380c..fcca8b18bafb602744c9befb8ab5971bace1a7a7 100644
(file)
--- a/
src/wx/wx_ptr.h
+++ b/
src/wx/wx_ptr.h
@@
-95,6
+95,7
@@
public:
{
if (_wx) {
_wx->Destroy();
+ _wx = nullptr;
}
_wx = new T(std::forward<Args>(args)...);
}