mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-04-24 09:38:32 +02:00
feat(wm): delete stale sub socket files
This commit is contained in:
@@ -316,6 +316,13 @@ pub fn notify_subscribers(notification: &str) -> Result<()> {
|
|||||||
for socket in stale_sockets {
|
for socket in stale_sockets {
|
||||||
tracing::warn!("removing stale subscription: {socket}");
|
tracing::warn!("removing stale subscription: {socket}");
|
||||||
sockets.remove(&socket);
|
sockets.remove(&socket);
|
||||||
|
let socket_path = DATA_DIR.join(socket);
|
||||||
|
if let Err(error) = std::fs::remove_file(&socket_path) {
|
||||||
|
tracing::error!(
|
||||||
|
"could not remove stale subscriber socket file at {}: {error}",
|
||||||
|
socket_path.display()
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let mut stale_pipes = vec![];
|
let mut stale_pipes = vec![];
|
||||||
|
|||||||
Reference in New Issue
Block a user