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

Unified Diff: media/filters/gpu_video_decoder.cc

Issue 9717021: Make Callback::Reset() return a copy to support use-cases where Run() ends up modifying |*this|. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: no base:: Created 8 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/filters/audio_renderer_base.cc ('k') | media/filters/video_renderer_base.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/gpu_video_decoder.cc
diff --git a/media/filters/gpu_video_decoder.cc b/media/filters/gpu_video_decoder.cc
index 4bb2f781539c3ad62c2cae53c6119b43c93b31d0..7ce3df75e74feaf68d9a6fbdf1ef9f3bcda8bd01 100644
--- a/media/filters/gpu_video_decoder.cc
+++ b/media/filters/gpu_video_decoder.cc
@@ -5,6 +5,7 @@
#include "media/filters/gpu_video_decoder.h"
#include "base/bind.h"
+#include "base/callback_helpers.h"
#include "base/message_loop.h"
#include "base/stl_util.h"
#include "media/base/demuxer_stream.h"
@@ -519,7 +520,7 @@ void GpuVideoDecoder::NotifyResetDone() {
input_buffer_time_data_.clear();
if (!pending_reset_cb_.is_null())
- ResetAndRunCB(&pending_reset_cb_);
+ base::ResetAndReturn(&pending_reset_cb_).Run();
if (!pending_read_cb_.is_null())
EnqueueFrameAndTriggerFrameDelivery(VideoFrame::CreateEmptyFrame());
« no previous file with comments | « media/filters/audio_renderer_base.cc ('k') | media/filters/video_renderer_base.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698