mirror of
https://github.com/hyprwm/Hyprland.git
synced 2024-09-20 09:38:48 +03:00
Fix broken pipe crash when event listener terminates (#2339)
This commit is contained in:
parent
5627b70981
commit
9f8c5cb63c
@ -108,7 +108,9 @@ void CEventManager::flushEvents() {
|
||||
for (auto& ev : m_dQueuedEvents) {
|
||||
std::string eventString = (ev.event + ">>" + ev.data).substr(0, 1022) + "\n";
|
||||
for (auto& fd : m_dAcceptedSocketFDs) {
|
||||
write(fd.first, eventString.c_str(), eventString.length());
|
||||
try {
|
||||
write(fd.first, eventString.c_str(), eventString.length());
|
||||
} catch(...) {}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user