Remove NullObjectReceiveStatistics() in rtp_rtcp module
use (already supported) nullptr as indication for no statistics BUG=webrtc:8016 Review-Url: https://codereview.webrtc.org/2983363002 Cr-Commit-Position: refs/heads/master@{#19129}
This commit is contained in:
parent
a04d9c31a0
commit
d3f3c3497b
@ -55,7 +55,7 @@ class RtpRtcp : public Module {
|
||||
// The clock to use to read time. If nullptr then system clock will be used.
|
||||
Clock* clock = nullptr;
|
||||
|
||||
ReceiveStatistics* receive_statistics;
|
||||
ReceiveStatistics* receive_statistics = nullptr;
|
||||
|
||||
// Transport object that will be called when packets are ready to be sent
|
||||
// out on the network.
|
||||
|
||||
@ -54,8 +54,7 @@ RTPExtensionType StringToRtpExtensionType(const std::string& extension) {
|
||||
return kRtpExtensionNone;
|
||||
}
|
||||
|
||||
RtpRtcp::Configuration::Configuration()
|
||||
: receive_statistics(NullObjectReceiveStatistics()) {}
|
||||
RtpRtcp::Configuration::Configuration() = default;
|
||||
|
||||
RtpRtcp* RtpRtcp::CreateRtpRtcp(const RtpRtcp::Configuration& configuration) {
|
||||
if (configuration.clock) {
|
||||
|
||||
@ -22,11 +22,6 @@ RtpFeedback* NullObjectRtpFeedback() {
|
||||
return &null_rtp_feedback;
|
||||
}
|
||||
|
||||
ReceiveStatistics* NullObjectReceiveStatistics() {
|
||||
static NullReceiveStatistics null_receive_statistics;
|
||||
return &null_receive_statistics;
|
||||
}
|
||||
|
||||
namespace RtpUtility {
|
||||
|
||||
enum {
|
||||
|
||||
@ -25,7 +25,6 @@ namespace webrtc {
|
||||
const uint8_t kRtpMarkerBitMask = 0x80;
|
||||
|
||||
RtpFeedback* NullObjectRtpFeedback();
|
||||
ReceiveStatistics* NullObjectReceiveStatistics();
|
||||
|
||||
namespace RtpUtility {
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user