Cache function templates in PluginObject to avoid memory leak.
commite85e45ea01bd4aeef48bf991012b198f7316470c
authorulan <ulan@chromium.org>
Wed, 10 Dec 2014 13:41:18 +0000 (10 05:41 -0800)
committerCommit bot <commit-bot@chromium.org>
Wed, 10 Dec 2014 13:41:36 +0000 (10 13:41 +0000)
treec153d1b00799d794aa5e365409131e59aaca654c
parent87d480ccc43d848591a3cf6b4e0d100d0c7d3679
Cache function templates in PluginObject to avoid memory leak.

Without caching, each call to PluginObject::GetPropertyOrMethod creates
a new function template. V8 stores all function templates internally
for the lifetime of the web-page.

BUG=439966

Review URL: https://codereview.chromium.org/785213002

Cr-Commit-Position: refs/heads/master@{#307691}
content/renderer/pepper/plugin_object.cc
content/renderer/pepper/plugin_object.h