Skip to content

Commit

Permalink
Merge pull request #1282 from yurp/fix_crash_in_negotiationneeded
Browse files Browse the repository at this point in the history
Fix crash in negotiationNeeded() when track is destroyed
paullouisageneau authored Oct 25, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
2 parents f8ffbe3 + ad68bb4 commit 848befc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/impl/peerconnection.cpp
Original file line number Diff line number Diff line change
@@ -1222,7 +1222,7 @@ bool PeerConnection::negotiationNeeded() const {
if (!media->isRemoved())
if (auto it = mTracks.find(media->mid()); it != mTracks.end())
if (auto track = it->second.lock(); !track || track->isClosed()) {
PLOG_DEBUG << "Negotiation needed to remove track, mid=" << track->mid();
PLOG_DEBUG << "Negotiation needed to remove track, mid=" << media->mid();
return true;
}
}

0 comments on commit 848befc

Please sign in to comment.