Chromium Code Reviews| Index: third_party/WebKit/Source/modules/webaudio/MediaStreamAudioDestinationNode.cpp |
| diff --git a/third_party/WebKit/Source/modules/webaudio/MediaStreamAudioDestinationNode.cpp b/third_party/WebKit/Source/modules/webaudio/MediaStreamAudioDestinationNode.cpp |
| index 1579cf3c8c8aea2c4931518fb42913c45ab98da1..022a6b17ddf3c2d91bd1048f7fcb078edf3e97cd 100644 |
| --- a/third_party/WebKit/Source/modules/webaudio/MediaStreamAudioDestinationNode.cpp |
| +++ b/third_party/WebKit/Source/modules/webaudio/MediaStreamAudioDestinationNode.cpp |
| @@ -122,8 +122,15 @@ MediaStreamAudioDestinationNode::MediaStreamAudioDestinationNode(AbstractAudioCo |
| setHandler(MediaStreamAudioDestinationHandler::create(*this, numberOfChannels)); |
| } |
| -MediaStreamAudioDestinationNode* MediaStreamAudioDestinationNode::create(AbstractAudioContext& context, size_t numberOfChannels) |
| +MediaStreamAudioDestinationNode* MediaStreamAudioDestinationNode::create(AbstractAudioContext& context, size_t numberOfChannels, ExceptionState& exceptionState) |
| { |
| + ASSERT(isMainThread()); |
|
hongchan
2016/05/13 01:20:12
DCHECK.
Raymond Toy
2016/05/20 23:12:00
Done.
|
| + |
| + if (context.isContextClosed()) { |
| + context.throwExceptionForClosedState(exceptionState); |
| + return nullptr; |
| + } |
| + |
| return new MediaStreamAudioDestinationNode(context, numberOfChannels); |
| } |