Chromium Code Reviews| Index: Source/bindings/v8/DOMDataStore.cpp |
| diff --git a/Source/bindings/v8/DOMDataStore.cpp b/Source/bindings/v8/DOMDataStore.cpp |
| index bbcac2b337fa65c7b8ec91c1e99134132eef33a2..39366c7a45b34d5f7e5be89d68fd781ae37b7341 100644 |
| --- a/Source/bindings/v8/DOMDataStore.cpp |
| +++ b/Source/bindings/v8/DOMDataStore.cpp |
| @@ -65,9 +65,12 @@ DOMDataStore* DOMDataStore::current(v8::Isolate* isolate) |
| return data->workerDOMDataStore(); |
| if (DOMWrapperWorld::isolatedWorldsExist()) { |
| - DOMWrapperWorld* isolatedWorld = DOMWrapperWorld::isolatedWorld(v8::Context::GetEntered()); |
| - if (UNLIKELY(!!isolatedWorld)) |
| - return isolatedWorld->isolatedWorldDOMDataStore(); |
| + v8::Local<v8::Context> context = v8::Context::GetEntered(); |
| + if (!context.IsEmpty()) { |
|
haraken
2013/10/25 05:21:23
This change makes sense. "If there is no entered c
|
| + DOMWrapperWorld* isolatedWorld = DOMWrapperWorld::isolatedWorld(context); |
| + if (UNLIKELY(!!isolatedWorld)) |
| + return isolatedWorld->isolatedWorldDOMDataStore(); |
| + } |
| } |
| return mainWorldStore(); |