Closed Bug 441424 Opened 16 years ago Closed 16 years ago
If there are any extensions that have a content policy (e
.g . Greasemonkey), then plugins (e .g . Flash) load twice
Adobe Flex Builder is running into a serious problem where our debugger -- which connects to the Flash Player over a TCP/IP connection -- isn't working. A lot of our users are running into this. I think I have this narrowed down to a problem with the way Firefox 3 loads plugins such as Flash whenever certain extensions are present. It seems that if there are any extensions that have a content policy, then plugins get an extra NPP_New/NPP_Destroy pair while the page is being loaded. In other words, the plugin see this: (when the user browses to the page, plugin sees this:) NPP_New NPP_Destroy NPP_New (then, when user browses away, plugin sees this:) NPP_Destroy The extra NPP_New/NPP_Destroy at the beginning are not expected, and are a change from previous behavior. I narrowed down when this change in behavior was introduced: - The 2008-04-14-06-trunk build works fine ( http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/2008/04/2008-04-14-06-trunk/firefox-3.0pre.en-US.win32.zip ); - the 2008-04-15-06-trunk build doesn't work ( http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/2008/04/2008-04-15-06-trunk/firefox-3.0pre.en-US.win32.zip ). Here is the repro case I have -- sorry this isn't easier. I followed these steps on Windows, but I can also reproduce the problem on Mac: 1. Disable all extensions (Greasemonkey etc.), and exit Firefox 2. Debug Firefox, e.g. with Visual Studio or another debugger 3. Set a breakpoint in ns4xPluginInstance.cpp line 955, which is in ns4xPluginInstance::Stop() where it has this line of code: NS_TRY_SAFE_CALL_RETURN(error, CallNPP_DestroyProc(fCallbacks->destroy, &fNPP, &sdata), fLibrary, this); That is a call to NPP_Destroy(). 4. Open debuggerproblemo.html, which just contains an <embed> tag to load a Flash application. So far, you have not hit the breakpoint. 5. Navigate to about:blank. As expected, you now hit the breakpoint, because the Flash plugin was destroyed when you left the page. 6. Now, install and enable Greasemonkey, and repeat the whole process. Results: When you have Greasemonkey installed, instead of NPP_Destroy being reached just once when you navigate away from the page that had Flash on it, you will see that NPP_Destroy is called twice: Once when the page is being loaded, and then again when you navigate away. P.S. I described a "content policy," but actually I don't even know what a content policy is -- I have never written a Firefox extension. That was the observation of one of the commenters on the Flex Builder bug, which is logged here: http://bugs.adobe.com/jira/browse/FB-13064
In case it is not obvious, I would like to add that this bug is a serious impediment to the development of any applications aimed at the Flash Player in Firefox 3, and may impede the migration to Firefox 3 for many Flash and Flex developers unable to debug their applications with the latest Firefox version.
I don't see anything directly related in Bonsai: http://bonsai.mozilla.org/cvsquery.cgi?module=PhoenixTinderbox&date=explicit&mindate=2008-04-14+05%3A00&maxdate=2008-04-15+07%3A00 Bug 423355 is probably the most likely candidate.
This seems to be an intermittent problem, not 100% reproducable. When I first installed Firefox 3 last week (about 7 days ago) my debugging in Flex Builder seemed to work fine with Firefox 3. Just today when doing some heavy debugging I noticed this issue popping up but was able to get debugging working again by trying a few times over. Now, at the end of the day, I am not able to get it working at all. Diabling the Greasemonkey and AdBlock extensions seemed to fix it for me but I can't keep Greasemonkey disabled, it's far too useful.
The fix for bug 438830 fixes this problem, which is really the same problem as reported in that bug, duping. Thanks for the testcase, made figuring this out way easier!
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.