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

Unified Diff: third_party/WebKit/Source/bindings/modules/v8/V8BindingForModules.cpp

Issue 1369773004: IndexedDB: Fix null ptr crash in IDBCursor::value(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added regression layout test. Created 5 years, 3 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
Index: third_party/WebKit/Source/bindings/modules/v8/V8BindingForModules.cpp
diff --git a/third_party/WebKit/Source/bindings/modules/v8/V8BindingForModules.cpp b/third_party/WebKit/Source/bindings/modules/v8/V8BindingForModules.cpp
index aa8877c95d1639df5c10f447eaa832765ef66e77..3eb6bba143634e02c448adf34cf41da9b72b1202 100644
--- a/third_party/WebKit/Source/bindings/modules/v8/V8BindingForModules.cpp
+++ b/third_party/WebKit/Source/bindings/modules/v8/V8BindingForModules.cpp
@@ -312,7 +312,7 @@ static IDBKey* createIDBKeyFromValueAndKeyPath(v8::Isolate* isolate, v8::Local<v
static v8::Local<v8::Value> deserializeIDBValueData(v8::Isolate* isolate, const IDBValue* value)
{
ASSERT(isolate->InContext());
- if (!value || value->isNull())
+ if (value->isNull())
return v8::Null(isolate);
const SharedBuffer* valueData = value->data();
@@ -324,7 +324,7 @@ static v8::Local<v8::Value> deserializeIDBValueData(v8::Isolate* isolate, const
static v8::Local<v8::Value> deserializeIDBValue(v8::Isolate* isolate, v8::Local<v8::Object> creationContext, const IDBValue* value)
{
ASSERT(isolate->InContext());
- if (!value || value->isNull())
+ if (value->isNull())
return v8::Null(isolate);
v8::Local<v8::Value> v8Value = deserializeIDBValueData(isolate, value);

Powered by Google App Engine
This is Rietveld 408576698