diff options
| author | Dan Engelbrecht <[email protected]> | 2023-05-24 15:15:02 +0200 |
|---|---|---|
| committer | GitHub <[email protected]> | 2023-05-24 15:15:02 +0200 |
| commit | c69b7341838f86f73519e20b83996b609cda7f6c (patch) | |
| tree | 394a00b17814c943059513f4781065c236753d3b /src/zencore/logging.cpp | |
| parent | cache log sessionid (#297) (diff) | |
| download | zen-c69b7341838f86f73519e20b83996b609cda7f6c.tar.xz zen-c69b7341838f86f73519e20b83996b609cda7f6c.zip | |
block destructors from throwing exceptions (#321)
* ~FileMapping() is not allowed to throw exceptions
* ~ScopedActivityBase() should not call ZEN_ASSERT (which causes SIGABORT on error)
* ProjectStore::Project::WriteAccessTimes() which is called from ProjectStore::~Project() must not throw exceptions
* changelog
Diffstat (limited to 'src/zencore/logging.cpp')
| -rw-r--r-- | src/zencore/logging.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/zencore/logging.cpp b/src/zencore/logging.cpp index 07b379cba..dc923f45e 100644 --- a/src/zencore/logging.cpp +++ b/src/zencore/logging.cpp @@ -131,7 +131,11 @@ ScopedActivityBase::ScopedActivityBase() : m_NextScope{t_ScopeStack} ScopedActivityBase::~ScopedActivityBase() { - ZEN_ASSERT(t_ScopeStack == this); + if (t_ScopeStack != this) + { + ZEN_ERROR("invalid t_ScopeStack in ~ScopedActivityBase(). Expected {:#x}, found {:#x}", (uintptr_t)this, (uintptr_t)t_ScopeStack); + return; + } t_ScopeStack = m_NextScope; } |