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

Unified Diff: third_party/WebKit/Source/core/html/HTMLIFrameElement.cpp

Issue 2191443002: Ensure the permissions DOMTokenList is initialized before access (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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/core/html/HTMLIFrameElement.cpp
diff --git a/third_party/WebKit/Source/core/html/HTMLIFrameElement.cpp b/third_party/WebKit/Source/core/html/HTMLIFrameElement.cpp
index a68f5d7774d4e23cd38ff2668fc0550fc47c248b..249f11600f42e8f949ae581b3b60c8c3d0fa1e5b 100644
--- a/third_party/WebKit/Source/core/html/HTMLIFrameElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLIFrameElement.cpp
@@ -61,8 +61,10 @@ DOMTokenList* HTMLIFrameElement::sandbox() const
return m_sandbox.get();
}
-DOMTokenList* HTMLIFrameElement::permissions() const
+DOMTokenList* HTMLIFrameElement::permissions()
{
+ if (!initializePermissionsAttribute())
esprehn 2016/07/27 06:05:56 How can this fail? Does the spec say it can be nul
raymes 2016/07/27 06:13:45 Sorry my description was inaccurate. It doesn't ac
+ return nullptr;
return m_permissions.get();
}

Powered by Google App Engine
This is Rietveld 408576698