Status: Unconfirmed
Owner: ----
Labels: Type-Bug Pri-2 OS-All Area-Misc

New issue 18405 by [email protected]: Extensions NPAPI bug: Plugin  
process created twice. Two separate NPObject instances presented to script.
http://code.google.com/p/chromium/issues/detail?id=18405

Chrome Version       : 3.0.196.0 (21423)

In my messing around with bundling an NPAPI plugin with an extension, I am
seeing the plugin process created, destroyed, and then subsequently created
again.

In fact, the inline script in my background page gets run only on the first
time the plugin process comes up, not the second time. If I grab a
reference to the plugin in inline script, the reference seems to remain
valid even after the plugin process goes away and comes back up again. I
know the instance is proxied across process boundaries, so it may be
possible that people don't notice that they are holding onto a different
NPObject instances since the other end of the reference seems to be swapped
in from underneath you.

What does this mean? It means that if you do anything stateful with an
NPObject reference in inline script, you are hosed. Any script triggered by
pageAction handlers interacts with a second instance of the plugin, that
gets created the second time the plugin process spawns.

Its pretty bad to have your background page interact with two different
instances of an NPAPI plugin :).

What steps will reproduce the problem?
1. Embed an NPAPI plugin using markup or inline javascript.
2. Start chrome with the --plugin-startup-dialog.
3. See two plugin processes come up and have fun with the debugger.

What is the expected result?
The plugin process should come up once! Inline script should interact with
the same plugin reference that script executed off event dispatches does.

What happens instead?
2 separate plugin instances in 2 separate, non-overlapping processes (one
comes up, goes down, the second comes up and stays).

Please provide any additional information below. Attach a screenshot if
possible.


--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

--~--~---------~--~----~------------~-------~--~----~
Automated mail from issue updates at http://crbug.com/
Subscription options: http://groups.google.com/group/chromium-bugs
-~----------~----~----~----~------~----~------~--~---

Reply via email to