Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "platform/v8_inspector/V8DebuggerAgentImpl.h" | 5 #include "platform/v8_inspector/V8DebuggerAgentImpl.h" |
| 6 | 6 |
| 7 #include "platform/inspector_protocol/String16.h" | 7 #include "platform/inspector_protocol/String16.h" |
| 8 #include "platform/inspector_protocol/Values.h" | 8 #include "platform/inspector_protocol/Values.h" |
| 9 #include "platform/v8_inspector/IgnoreExceptionsScope.h" | 9 #include "platform/v8_inspector/IgnoreExceptionsScope.h" |
| 10 #include "platform/v8_inspector/InjectedScript.h" | 10 #include "platform/v8_inspector/InjectedScript.h" |
| (...skipping 978 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 989 *errorString = "Can not access given context"; | 989 *errorString = "Can not access given context"; |
| 990 return; | 990 return; |
| 991 } | 991 } |
| 992 | 992 |
| 993 size_t frameOrdinal = static_cast<size_t>(remoteId->frameOrdinal()); | 993 size_t frameOrdinal = static_cast<size_t>(remoteId->frameOrdinal()); |
| 994 if (frameOrdinal >= m_pausedCallFrames.size()) { | 994 if (frameOrdinal >= m_pausedCallFrames.size()) { |
| 995 *errorString = "Could not find call frame with given id"; | 995 *errorString = "Could not find call frame with given id"; |
| 996 return; | 996 return; |
| 997 } | 997 } |
| 998 | 998 |
| 999 v8::MaybeLocal<v8::Object> commandLineAPI = includeCommandLineAPI.fromMaybe( false) ? injectedScript->commandLineAPI(errorString) : v8::MaybeLocal<v8::Object >(); | 999 v8::MaybeLocal<v8::Object> commandLineAPI = (includeCommandLineAPI.fromMaybe (false) && false) ? injectedScript->commandLineAPI(errorString) : v8::MaybeLocal <v8::Object>(); |
|
dgozman
2016/04/04 22:45:34
Do we have a test?
kozy
2016/04/04 23:28:14
Yes, I've uploaded not last version. Fixed.
| |
| 1000 if (includeCommandLineAPI.fromMaybe(false) && commandLineAPI.IsEmpty()) | 1000 if (includeCommandLineAPI.fromMaybe(false) && commandLineAPI.IsEmpty()) |
| 1001 return; | 1001 return; |
| 1002 | 1002 |
| 1003 InjectedScript::ScopedGlobalObjectExtension scopeExtension(injectedScript, c ommandLineAPI); | 1003 InjectedScript::ScopedGlobalObjectExtension scopeExtension(injectedScript, c ommandLineAPI); |
| 1004 | 1004 |
| 1005 v8::TryCatch tryCatch(injectedScript->isolate()); | 1005 v8::TryCatch tryCatch(injectedScript->isolate()); |
| 1006 | 1006 |
| 1007 v8::MaybeLocal<v8::Value> maybeResultValue = m_pausedCallFrames[frameOrdinal ].get()->evaluate(toV8String(injectedScript->isolate(), expression)); | 1007 v8::MaybeLocal<v8::Value> maybeResultValue = m_pausedCallFrames[frameOrdinal ].get()->evaluate(toV8String(injectedScript->isolate(), expression)); |
| 1008 | 1008 |
| 1009 // InjectedScript may be gone after any evaluate call - find it again. | 1009 // InjectedScript may be gone after any evaluate call - find it again. |
| (...skipping 624 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1634 if (!enabled()) | 1634 if (!enabled()) |
| 1635 return; | 1635 return; |
| 1636 m_scheduledDebuggerStep = NoStep; | 1636 m_scheduledDebuggerStep = NoStep; |
| 1637 m_scripts.clear(); | 1637 m_scripts.clear(); |
| 1638 m_blackboxedPositions.clear(); | 1638 m_blackboxedPositions.clear(); |
| 1639 m_breakpointIdToDebuggerBreakpointIds.clear(); | 1639 m_breakpointIdToDebuggerBreakpointIds.clear(); |
| 1640 resetAsyncCallTracker(); | 1640 resetAsyncCallTracker(); |
| 1641 } | 1641 } |
| 1642 | 1642 |
| 1643 } // namespace blink | 1643 } // namespace blink |
| OLD | NEW |