mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-26 05:05:59 +01:00
hookSystem: Make needsDeadCleanup volatile (#6356)
The value of needsDeadCleanup would be clobbered after longjmp, having an undefined value.
This commit is contained in:
parent
af5f24929d
commit
429cff340d
1 changed files with 2 additions and 2 deletions
|
@ -28,7 +28,7 @@ void CHookSystemManager::emit(std::vector<SCallbackFNPtr>* const callbacks, SCal
|
||||||
return;
|
return;
|
||||||
|
|
||||||
std::vector<HANDLE> faultyHandles;
|
std::vector<HANDLE> faultyHandles;
|
||||||
bool needsDeadCleanup = false;
|
volatile bool needsDeadCleanup = false;
|
||||||
|
|
||||||
for (auto& cb : *callbacks) {
|
for (auto& cb : *callbacks) {
|
||||||
|
|
||||||
|
@ -80,4 +80,4 @@ std::vector<SCallbackFNPtr>* CHookSystemManager::getVecForEvent(const std::strin
|
||||||
Debug::log(LOG, "[hookSystem] New hook event registered: {}", event);
|
Debug::log(LOG, "[hookSystem] New hook event registered: {}", event);
|
||||||
|
|
||||||
return &m_mRegisteredHooks[event];
|
return &m_mRegisteredHooks[event];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue