packages/ak-axum/server: fix unix socket cleanup when allow_failure is unset (#21645)

This commit is contained in:
Marc 'risson' Schmitt
2026-04-16 16:20:16 +00:00
committed by GitHub
parent d51296cbb9
commit 05bb1d1fdd
+1 -1
View File
@@ -84,7 +84,7 @@ pub(crate) async fn run_unix(
.handle(handle)
.serve(router.into_make_service())
.await;
if let Some(path) = addr.as_pathname() {
if !allow_failure && let Some(path) = addr.as_pathname() {
trace!(?addr, "removing socket");
if let Err(err) = std::fs::remove_file(path) {
trace!(?err, "failed to remove socket, ignoring");