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

Unified Diff: webrtc/video/rtc_event_log.cc

Issue 1295753003: Convenience functions to convert RtcEvents to webrtc types. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Rebase and change CHECK to RTC_CHECK Created 5 years, 3 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
« no previous file with comments | « webrtc/video/rtc_event_log.h ('k') | webrtc/video/rtc_event_log2rtp_dump.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/video/rtc_event_log.cc
diff --git a/webrtc/video/rtc_event_log.cc b/webrtc/video/rtc_event_log.cc
index 8e6d1b9f224247f3af9dbdcac38eaa9c861d243d..509b44655b46ccb17b061c61fdd00fb52959d8fc 100644
--- a/webrtc/video/rtc_event_log.cc
+++ b/webrtc/video/rtc_event_log.cc
@@ -10,12 +10,14 @@
#include "webrtc/video/rtc_event_log.h"
+#include <string>
#include <deque>
#include "webrtc/base/checks.h"
#include "webrtc/base/criticalsection.h"
#include "webrtc/base/thread_annotations.h"
#include "webrtc/call.h"
+#include "webrtc/modules/rtp_rtcp/interface/rtp_rtcp_defines.h"
#include "webrtc/modules/rtp_rtcp/source/byte_io.h"
#include "webrtc/system_wrappers/interface/clock.h"
#include "webrtc/system_wrappers/interface/file_wrapper.h"
@@ -380,21 +382,6 @@ void RtcEventLogImpl::AddRecentEvent(const rtclog::Event& event) {
}
}
-bool RtcEventLog::ParseRtcEventLog(const std::string& file_name,
- rtclog::EventStream* result) {
- char tmp_buffer[1024];
- int bytes_read = 0;
- rtc::scoped_ptr<FileWrapper> dump_file(FileWrapper::Create());
- if (dump_file->OpenFile(file_name.c_str(), true) != 0) {
- return false;
- }
- std::string dump_buffer;
- while ((bytes_read = dump_file->Read(tmp_buffer, sizeof(tmp_buffer))) > 0) {
- dump_buffer.append(tmp_buffer, bytes_read);
- }
- dump_file->CloseFile();
- return result->ParseFromString(dump_buffer);
-}
#endif // ENABLE_RTC_EVENT_LOG
@@ -402,4 +389,5 @@ bool RtcEventLog::ParseRtcEventLog(const std::string& file_name,
rtc::scoped_ptr<RtcEventLog> RtcEventLog::Create() {
return rtc::scoped_ptr<RtcEventLog>(new RtcEventLogImpl());
}
+
} // namespace webrtc
« no previous file with comments | « webrtc/video/rtc_event_log.h ('k') | webrtc/video/rtc_event_log2rtp_dump.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698