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

Unified Diff: webrtc/api/sctputils.h

Issue 1823503002: Reland Use CopyOnWriteBuffer instead of Buffer to avoid unnecessary copies. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 9 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/api/sctputils.h
diff --git a/webrtc/api/sctputils.h b/webrtc/api/sctputils.h
index ffbade2f0ca46fb20db4681acf6fe54062a26fbb..2fb194330c3cc04ec514fd0d97d57a150557715c 100644
--- a/webrtc/api/sctputils.h
+++ b/webrtc/api/sctputils.h
@@ -16,26 +16,26 @@
#include "webrtc/api/datachannelinterface.h"
namespace rtc {
-class Buffer;
+class CopyOnWriteBuffer;
} // namespace rtc
namespace webrtc {
struct DataChannelInit;
// Read the message type and return true if it's an OPEN message.
-bool IsOpenMessage(const rtc::Buffer& payload);
+bool IsOpenMessage(const rtc::CopyOnWriteBuffer& payload);
-bool ParseDataChannelOpenMessage(const rtc::Buffer& payload,
+bool ParseDataChannelOpenMessage(const rtc::CopyOnWriteBuffer& payload,
std::string* label,
DataChannelInit* config);
-bool ParseDataChannelOpenAckMessage(const rtc::Buffer& payload);
+bool ParseDataChannelOpenAckMessage(const rtc::CopyOnWriteBuffer& payload);
bool WriteDataChannelOpenMessage(const std::string& label,
const DataChannelInit& config,
- rtc::Buffer* payload);
+ rtc::CopyOnWriteBuffer* payload);
-void WriteDataChannelOpenAckMessage(rtc::Buffer* payload);
+void WriteDataChannelOpenAckMessage(rtc::CopyOnWriteBuffer* payload);
} // namespace webrtc
#endif // WEBRTC_API_SCTPUTILS_H_

Powered by Google App Engine
This is Rietveld 408576698