We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f369f47 commit 10bd8e3Copy full SHA for 10bd8e3
1 file changed
dll/steam_matchmaking.cpp
@@ -686,6 +686,15 @@ void Steam_Matchmaking::LeaveLobby( CSteamID steamIDLobby )
686
PRINT_DEBUG_ENTRY();
687
std::lock_guard<std::recursive_mutex> lock(global_mutex);
688
PRINT_DEBUG("pass mutex");
689
+
690
+ // Discard any deferred LobbyEnter_t; no point delivering an enter for a lobby that’s already being left
691
+ pending_lobby_enters.erase(
692
+ std::remove_if(pending_lobby_enters.begin(), pending_lobby_enters.end(),
693
+ [&steamIDLobby](const Pending_Lobby_Enter &p) {
694
+ return p.lobby_id == steamIDLobby.ConvertToUint64();
695
+ }),
696
+ pending_lobby_enters.end());
697
698
Lobby *lobby = get_lobby(steamIDLobby);
699
if (lobby) {
700
if (!lobby->deleted()) {
0 commit comments