From 00cf036d589626ea9f44a13bfe128c1dc5295155 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Thu, 1 Feb 2024 17:01:31 +0100 Subject: [PATCH] lib/avahi/Client: relax assertion after COLLISION/REGISTERING Turns out that `AVAHI_CLIENT_S_COLLISION` can occur after `AVAHI_CLIENT_S_RUNNING`, and `connected==true`. Relaxing this fixes a bogus assertion failure. --- src/lib/avahi/Client.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/avahi/Client.cxx b/src/lib/avahi/Client.cxx index 955641449..454e99130 100644 --- a/src/lib/avahi/Client.cxx +++ b/src/lib/avahi/Client.cxx @@ -79,7 +79,7 @@ Client::ClientCallback(AvahiClient *c, AvahiClientState state) noexcept case AVAHI_CLIENT_S_COLLISION: case AVAHI_CLIENT_S_REGISTERING: - assert(!connected); + connected = false; for (auto *l : listeners) l->OnAvahiChanged();