Open Bug 807633 Opened 12 years ago Updated 2 years ago

WebRTC data race with webrtc::RTPSender::SendToNetwork vs. webrtc::RTPSender::Bytes

Categories

(Core :: WebRTC: Networking, defect, P4)

x86
Linux
defect

Tracking

()

People

(Reporter: posidron, Unassigned)

References

Details

(Whiteboard: [tsan])

Attachments

(1 file)

Attached file callstack
media/webrtc/trunk/src/modules/rtp_rtcp/source/rtp_sender.cc:947 // Update send statistics CriticalSectionScoped cs(_sendCritsect); Bitrate::Update(bytes_sent); _packetsSent++; if (bytes_sent > rtpLength) { _payloadBytesSent += bytes_sent - rtpLength; } media/webrtc/trunk/src/modules/rtp_rtcp/source/rtp_sender.cc:1007 // number of sent RTP bytes // dont use critsect to avoid potental deadlock WebRtc_UWord32 RTPSender::Bytes() const { return _payloadBytesSent; } Tested with m-c changeset: 111684:e19e170d2f6d
Is RTPSender::Bytes() used anywhere that this race condition would matter? Or is it just a stat.
Another concurrent read has been identified in: webrtc::RTPSender::Packets /trunk/src/modules/rtp_rtcp/source/rtp_sender.cc:999
Same question.
WebRtc_Word32 ModuleRtpRtcpImpl::DataCountersRTP( WebRtc_UWord32* bytesSent, WebRtc_UWord32* packetsSent, WebRtc_UWord32* bytesReceived, WebRtc_UWord32* packetsReceived) const { WEBRTC_TRACE(kTraceStream, kTraceRtpRtcp, _id, "DataCountersRTP()"); if (bytesSent) { *bytesSent = _rtpSender.Bytes(); } if (packetsSent) { *packetsSent = _rtpSender.Packets(); } return _rtpReceiver.DataCounters(bytesReceived, packetsReceived); }
this sure sounds like it's just a statistics interface.
Priority: -- → P3
Whiteboard: [tsan] → [tsan][WebRTC][blocking-webrtc-]
See Issue 879 at webrtc.org's Issue tracker
backlog: --- → webRTC+
Rank: 33
Whiteboard: [tsan][WebRTC][blocking-webrtc-] → [tsan]
Mass change P3->P4 to align with new Mozilla triage process.
Priority: P3 → P4
Has Regression Range: --- → irrelevant
QA Whiteboard: qa-not-actionable

In the process of migrating remaining bugs to the new severity system, the severity for this bug cannot be automatically determined. Please retriage this bug using the new severity system.

Severity: major → --
Severity: -- → S4
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: