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

Unified Diff: media/formats/webm/webm_stream_parser.cc

Issue 195973006: Allow StreamParsers to request automatic timestampOffset updates. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add ADTS tests. Created 6 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
« no previous file with comments | « media/formats/mpeg/mpeg_audio_stream_parser_base.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/formats/webm/webm_stream_parser.cc
diff --git a/media/formats/webm/webm_stream_parser.cc b/media/formats/webm/webm_stream_parser.cc
index fcb55deed365b6c0ab464de77e275c9e5a7bef2e..eae0371f0654960b1c54a209836b1e3f0cd3c431 100644
--- a/media/formats/webm/webm_stream_parser.cc
+++ b/media/formats/webm/webm_stream_parser.cc
@@ -7,6 +7,7 @@
#include <string>
#include "base/callback.h"
+#include "base/callback_helpers.h"
#include "base/logging.h"
#include "media/formats/webm/webm_cluster_parser.h"
#include "media/formats/webm/webm_constants.h"
@@ -214,10 +215,8 @@ int WebMStreamParser::ParseInfoAndTracks(const uint8* data, int size) {
ChangeState(kParsingClusters);
- if (!init_cb_.is_null()) {
- init_cb_.Run(true, duration);
- init_cb_.Reset();
- }
+ if (!init_cb_.is_null())
+ base::ResetAndReturn(&init_cb_).Run(true, duration, false);
return bytes_parsed;
}
« no previous file with comments | « media/formats/mpeg/mpeg_audio_stream_parser_base.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698