Cockatrice/cockatrice/src
BruebachL 9acb9739b2
[Client] Fix spurious server room join error (#7259)
* [Client] Fix spurious server room join error

The server replies RespContextError when a join command is received for a
room that connection is already registered in. The client was sending such
duplicate joins in benign situations - double-clicking to join a room, or
clicking a room the selector was already auto-joining - and answered them
with a modal telling users to restart the client.

Joins for the same room are now deduplicated while one is in flight, and a
remaining RespContextError is healed by leaving and rejoining the room so
the tab appears without a client restart. Error dialogs are only shown for
user-initiated joins, so failed auto-joins no longer spam critical popups.

* [Client] Bound stale-membership room join heal to one attempt

The RespContextError heal (leave + rejoin) previously recurred
unconditionally, so a server that kept returning RespContextError for a
reason other than stale membership would loop forever. Track room ids
that already received a heal and surface the error dialog after one
attempt instead of retrying indefinitely.

* [Client] Scope room-join heal guard to one join attempt

* [Client] Hoist room-join heal guard lookup out of response switch

---------

Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
2026-09-19 09:56:09 +02:00
..
client Use capitalized app names (#7255) 2026-09-12 17:30:46 +02:00
database/interface [Settings] Split cache_settings monolith into multiple SettingsManager sub-classes (#7050) 2026-07-27 11:25:39 +02:00
filters Migrate theme asset loads to scheme-variant resolution (#7209-2) (#7276) 2026-09-11 17:59:57 +02:00
game [Game] Preserve hand card order when restoring connection (#7266) 2026-09-07 08:21:44 +02:00
game_graphics [Client] Show localized card names, texts and pictures (#7294) 2026-09-18 12:03:07 +02:00
interface [Client] Fix spurious server room join error (#7259) 2026-09-19 09:56:09 +02:00
main.cpp Use capitalized app names (#7255) 2026-09-12 17:30:46 +02:00
main.h Standardize Doxygen documentation (#6885) 2026-05-21 22:58:07 +02:00
single_instance_manager.cpp Define Cockatrice as an editor/handler for .cod files and cockatrice:// protocol on all platforms (#6775) 2026-08-08 19:02:19 +02:00
single_instance_manager.h Define Cockatrice as an editor/handler for .cod files and cockatrice:// protocol on all platforms (#6775) 2026-08-08 19:02:19 +02:00