From 0349fdfd679b80998cf950210823cc2dc28f2ba5 Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Mon, 23 Jun 2014 21:50:28 +0800 Subject: [PATCH] Fix converting empty V8 dictionary. --- atom/common/native_mate_converters/value_converter.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/atom/common/native_mate_converters/value_converter.cc b/atom/common/native_mate_converters/value_converter.cc index 626917d62054..79848b28bf44 100644 --- a/atom/common/native_mate_converters/value_converter.cc +++ b/atom/common/native_mate_converters/value_converter.cc @@ -15,7 +15,7 @@ bool Converter::FromV8(v8::Isolate* isolate, scoped_ptr converter(new atom::V8ValueConverter); scoped_ptr value(converter->FromV8Value( val, v8::Context::GetCurrent())); - if (value->IsType(base::Value::TYPE_DICTIONARY)) { + if (value && value->IsType(base::Value::TYPE_DICTIONARY)) { out->Swap(static_cast(value.get())); return true; } else {