Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Unified Diff: webrtc/common_types.h

Issue 2981513002: Wire up RTP keep-alive in ortc api. (Closed)
Patch Set: wip Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/common_types.h
diff --git a/webrtc/common_types.h b/webrtc/common_types.h
index 03d8ac9281ac64675e327ba5f2bac77f69cc3c71..729cae31b263fba4289f9a7ab40789f68a27fbd8 100644
--- a/webrtc/common_types.h
+++ b/webrtc/common_types.h
@@ -912,7 +912,7 @@ enum NetworkState {
kNetworkDown,
};
-struct RtpKeepAliveConfig {
+struct RtpKeepAliveConfig final {
// If no packet has been sent for |timeout_interval_ms|, send a keep-alive
// packet. The keep-alive packet is an empty (no payload) RTP packet with a
// payload type of 20 as long as the other end has not negotiated the use of
@@ -921,6 +921,12 @@ struct RtpKeepAliveConfig {
// in |payload_type|.
int64_t timeout_interval_ms = -1;
uint8_t payload_type = 20;
+
+ bool operator==(const RtpKeepAliveConfig& o) const {
+ return timeout_interval_ms == o.timeout_interval_ms &&
+ payload_type == o.payload_type;
+ }
+ bool operator!=(const RtpKeepAliveConfig& o) const { return !(*this == o); }
};
} // namespace webrtc

Powered by Google App Engine
This is Rietveld 408576698