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

Unified Diff: Source/bindings/v8/custom/V8HTMLFormElementCustom.cpp

Issue 25403004: [oilpan] Figure out lifetime of remaining Node raw pointers (Part 2) (Closed) Base URL: svn://svn.chromium.org/blink/branches/oilpan
Patch Set: Created 7 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: Source/bindings/v8/custom/V8HTMLFormElementCustom.cpp
diff --git a/Source/bindings/v8/custom/V8HTMLFormElementCustom.cpp b/Source/bindings/v8/custom/V8HTMLFormElementCustom.cpp
index d825e9646ee6d4fd56655caf94aef3d0de31e1f4..747f7d5b313bb6e8b798282004dbf7c17cb94489 100644
--- a/Source/bindings/v8/custom/V8HTMLFormElementCustom.cpp
+++ b/Source/bindings/v8/custom/V8HTMLFormElementCustom.cpp
@@ -43,7 +43,7 @@ namespace WebCore {
v8::Handle<v8::Value> V8HTMLFormElement::indexedPropertyGetter(uint32_t index, const v8::AccessorInfo& info)
{
HandleScope handleScope;
- HTMLFormElement* form = V8HTMLFormElement::toNative(info.Holder());
+ Handle<HTMLFormElement> form = adoptRawResult(V8HTMLFormElement::toNative(info.Holder()));
Handle<Node> formElement = form->elements()->item(index);
if (!formElement)
@@ -54,7 +54,7 @@ v8::Handle<v8::Value> V8HTMLFormElement::indexedPropertyGetter(uint32_t index, c
v8::Handle<v8::Value> V8HTMLFormElement::namedPropertyGetter(v8::Local<v8::String> name, const v8::AccessorInfo& info)
{
HandleScope handleScope;
- HTMLFormElement* imp = V8HTMLFormElement::toNative(info.Holder());
+ Handle<HTMLFormElement> imp = adoptRawResult(V8HTMLFormElement::toNative(info.Holder()));
AtomicString v = toWebCoreAtomicString(name);
// Call getNamedElements twice, first time check if it has a value
@@ -76,7 +76,7 @@ v8::Handle<v8::Value> V8HTMLFormElement::namedPropertyGetter(v8::Local<v8::Strin
if (elements->size() == 1)
return toV8Fast(elements[0].handle(), info, imp);
- return toV8Fast(V8NamedNodesCollection::create(*elements), info, imp);
+ return toV8Fast(V8NamedNodesCollection::create(*elements), info, imp.raw());
}
} // namespace WebCore

Powered by Google App Engine
This is Rietveld 408576698