-
beidson@apple.com authored
<rdar://problem/12142226> and https://bugs.webkit.org/show_bug.cgi?id=95026 Source/WebKit2: Patch partially by Andras Becsi <andras.becsi@nokia.com> Reviewed by Andy Estes. If a plug-in fails to initialize then the m_plugin pointer is cleared out. When accessing the script object it is appropriate to unconditionally null check m_plugin. * WebProcess/Plugins/PluginView.cpp: (WebKit::PluginView::scriptObject): Null check m_plugin before trying to use it. Tools: Reviewed by Andy Estes. Add a plug-in that always fails to initialize: * DumpRenderTree/TestNetscapePlugIn/Tests/NPPNewFails.cpp: Added. (NPPNewFails): (NPPNewFails::NPPNewFails): (NPPNewFails::NPP_New): Add it to all the project files: * DumpRenderTree/DumpRenderTree.gypi: * DumpRenderTree/DumpRenderTree.xcodeproj/project.pbxproj: * DumpRenderTree/TestNetscapePlugIn/CMakeLists.txt: * DumpRenderTree/TestNetscapePlugIn/win/TestNetscapePlugin.vcproj: * DumpRenderTree/qt/TestNetscapePlugin/TestNetscapePlugin.pro: LayoutTests: Reviewed by Andy Estes. * plugins/npp-new-fails-expected.txt: Added. * plugins/npp-new-fails.html: Added. git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127595 268f45cc-cd09-0410-ab3c-d52691b4dbfc
65e67acb