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

Side by Side Diff: content/renderer/pepper_platform_video_decoder_impl.cc

Issue 7467037: Made Destroy() followup more aggressive to test for races. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 9 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/pepper_platform_video_decoder_impl.h" 5 #include "content/renderer/pepper_platform_video_decoder_impl.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 } 74 }
75 75
76 void PlatformVideoDecoderImpl::Reset() { 76 void PlatformVideoDecoderImpl::Reset() {
77 DCHECK(decoder_); 77 DCHECK(decoder_);
78 decoder_->Reset(); 78 decoder_->Reset();
79 } 79 }
80 80
81 void PlatformVideoDecoderImpl::Destroy() { 81 void PlatformVideoDecoderImpl::Destroy() {
82 DCHECK(decoder_); 82 DCHECK(decoder_);
83 decoder_->Destroy(); 83 decoder_->Destroy();
84 client_ = NULL;
85 decoder_ = NULL;
84 } 86 }
85 87
86 void PlatformVideoDecoderImpl::NotifyEndOfStream() { 88 void PlatformVideoDecoderImpl::NotifyEndOfStream() {
87 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); 89 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current());
88 client_->NotifyEndOfStream(); 90 client_->NotifyEndOfStream();
89 } 91 }
90 92
91 void PlatformVideoDecoderImpl::NotifyError( 93 void PlatformVideoDecoderImpl::NotifyError(
92 VideoDecodeAccelerator::Error error) { 94 VideoDecodeAccelerator::Error error) {
93 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); 95 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current());
(...skipping 30 matching lines...) Expand all
124 126
125 void PlatformVideoDecoderImpl::NotifyFlushDone() { 127 void PlatformVideoDecoderImpl::NotifyFlushDone() {
126 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); 128 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current());
127 client_->NotifyFlushDone(); 129 client_->NotifyFlushDone();
128 } 130 }
129 131
130 void PlatformVideoDecoderImpl::NotifyResetDone() { 132 void PlatformVideoDecoderImpl::NotifyResetDone() {
131 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current()); 133 DCHECK_EQ(RenderThread::current()->message_loop(), MessageLoop::current());
132 client_->NotifyResetDone(); 134 client_->NotifyResetDone();
133 } 135 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698