diff --git a/media/mtransport/nricectx.cpp b/media/mtransport/nricectx.cpp index 551d7ef175f4..64e66bb9751f 100644 --- a/media/mtransport/nricectx.cpp +++ b/media/mtransport/nricectx.cpp @@ -317,6 +317,10 @@ void NrIceCtx::DestroyStream(const std::string& id) { streams_.erase(it); preexisting_stream->Close(); } + + if (streams_.empty()) { + SetGatheringState(ICE_CTX_GATHER_INIT); + } } // Handler callbacks