Last Comment Bug 737433 - flash not loaded
: flash not loaded
: regression
Product: Core
Classification: Components
Component: Plug-ins (show other bugs)
: Trunk
: x86 Windows XP
: -- normal (vote)
: mozilla13
Assigned To: Benjamin Smedberg [:bsmedberg]
: Benjamin Smedberg [:bsmedberg]
Depends on: 776451
Blocks: 90268
  Show dependency treegraph
Reported: 2012-03-20 08:09 PDT by
Modified: 2012-08-11 12:39 PDT (History)
10 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

FlashNotLoaded.jpg (332.92 KB, image/jpeg)
2012-03-20 08:09 PDT,
no flags Details
Pass the content the embedded stream initiator, rev. 1 (5.52 KB, patch)
2012-03-20 12:31 PDT, Benjamin Smedberg [:bsmedberg]
jaas: review-
Details | Diff | Splinter Review
Pass the content the embedded stream initiator, rev. 1.1 (4.55 KB, patch)
2012-03-28 10:37 PDT, Benjamin Smedberg [:bsmedberg]
jaas: review+
lukasblakk+bugs: approval‑mozilla‑aurora+
Details | Diff | Splinter Review

Description 2012-03-20 08:09:16 PDT
Created attachment 607556 [details]

User Agent: Mozilla/5.0 (Windows NT 5.1; rv:14.0) Gecko/20120320 Firefox/14.0a1
Build ID: 20120320031130

Steps to reproduce:


Actual results:

The page loaded but not flash. It says "Movie not loaded" when o right click in the flash area

Expected results:

The flash should be loaded
Comment 1 Matthias Versen [:Matti] 2012-03-20 10:00:18 PDT
The referer header is missing !
Benjamin: Could this be a regression from bug 724465 ?

GET /bin/flash/vrs1.1/prev.meteo.sam.portugal.v2011.2.swf HTTP/1.1
User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:14.0) Gecko/20120315 Firefox/14.0a1 SeaMonkey/2.11a1
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: de-de,de;q=0.8,en-us;q=0.5,en;q=0.3
Accept-Encoding: gzip, deflate
DNT: 1
Connection: keep-alive

Expires: Wed, 21 Mar 2012 16:37:56 GMT
Cache-Control: max-age=86400
Content-Type: application/x-shockwave-flash
Content-Length: 14379
Connection: close
HTTP/1.1 403 Forbidden
Date: Tue, 20 Mar 2012 16:28:53 GMT
Server: Apache
Content-Length: 254
Connection: close
Content-Type: text/html; charset=iso-8859-1
GET /opencms/bin/flash/vrs1.1/prev.meteo.sam.portugal.v2011.2.swf HTTP/1.1
User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:11.0) Gecko/20100101 Firefox/11.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: en-us,en;q=0.5
Accept-Encoding: gzip, deflate
Connection: keep-alive

HTTP/1.1 302 Found
Date: Tue, 20 Mar 2012 16:51:50 GMT
Server: Apache
Content-Length: 256
Connection: close
Content-Type: text/html; charset=iso-8859-1
Comment 2 Benjamin Smedberg [:bsmedberg] 2012-03-20 10:13:29 PDT
Without a regression range I don't know. It could also be bug 729009. What are the two HTTP logs you've listed?
Comment 3 Benjamin Smedberg [:bsmedberg] 2012-03-20 10:14:01 PDT
Is this problem present in Firefox 12 beta or Firefox 13 aurora?
Comment 4 Matthias Versen [:Matti] 2012-03-20 10:29:00 PDT
I already started with the regression range searching after confirming.
The 2 http logs are from a nightly Seamonkey and Firefox11 as you can see by the UA string. 
I pasted the wrong http request for FF11 (the 302) but the final request shows also a referer header while the trunk GET request is without.
The request is the actual request by Gecko for the swf referenced by an object tag.

Last good nightly: 2012-01-31
First bad nightly: 2012-02-01


bug 90268 ?
Comment 5 Benjamin Smedberg [:bsmedberg] 2012-03-20 12:31:50 PDT
Created attachment 607661 [details] [diff] [review]
Pass the content the embedded stream initiator, rev. 1

Josh, I'm wondering if there was a reason for passing nsnull here, or whether this was just a thinko in the original patch: this version passes tests, but my "weird side-effects" radar is going off.
Comment 6 Josh Aas 2012-03-20 16:56:07 PDT
Comment on attachment 607661 [details] [diff] [review]
Pass the content the embedded stream initiator, rev. 1

Review of attachment 607661 [details] [diff] [review]:

I think it is a thinko, and I think I know what my original logic was (described below). Your patch seems like a fine approach, but there are two remaining issues.

You will trip the assertion at the top of nsPluginHost::NewEmbeddedPluginStream since both values can be non-null:

NS_ASSERTION(!aContent || !aInstance, "Don't pass both content and an instance to NewEmbeddedPluginStream!");

I think, and the assertion corroborates, that my original logic was that content or the instance should be passed in, never both. This was probably based on the 'if' statement at the core of nsPluginHost::NewEmbeddedPluginStreamListener. However, since the first check is for the instance then it doesn't really hurt to have an instance and content, and the content is needed for the referrer code in nsPluginHost::NewEmbeddedPluginStream. This also holds safely true when we check for an instance first in nsPluginStreamListenerPeer::InitializeEmbedded.

The second issue is that the test fails locally on Fedora 16. Oddly, it succeeds as part of a full plugin tests run but it fails when you run it individually.

I have to minus on the assertion problem and the test failure, but once that is fixed up I think we're good. Thanks for fixing this!
Comment 7 Benjamin Smedberg [:bsmedberg] 2012-03-28 10:37:55 PDT
Created attachment 610194 [details] [diff] [review]
Pass the content the embedded stream initiator, rev. 1.1

I removed the assertion. I cannot reproduce any test failures, but I've removed the unnecessary changes in test_pluginstream_referer.html (I had originally tried to combine the tests, but that seems silly). I've kicked off a try run.
Comment 8 Benjamin Smedberg [:bsmedberg] 2012-03-29 11:25:04 PDT
Comment 9 Ed Morley [:emorley] 2012-03-30 13:07:01 PDT
Comment 10 Benjamin Smedberg [:bsmedberg] 2012-03-30 13:16:46 PDT
Comment on attachment 610194 [details] [diff] [review]
Pass the content the embedded stream initiator, rev. 1.1

Regression caused by (bug #): bug 90268
User impact if declined: Some websites with embedded Flash will stop working
Testing completed (on m-c, etc.): Just landed on m-c, will probably want a few days to shake out. Comes with automated tests.
Risk to taking this patch (and alternatives if risky): I believe that we are strictly returning to the previous behavior. The risk is just that the patch is wrong somehow, which given my current understanding seems pretty unlikely.
Comment 11 Lukas Blakk [:lsblakk] use ?needinfo 2012-04-03 11:32:26 PDT
Comment on attachment 610194 [details] [diff] [review]
Pass the content the embedded stream initiator, rev. 1.1

[Triage Comment]
Landing for m-c/81975c3ca494 looks good, approved.
Comment 12 Lukas Blakk [:lsblakk] use ?needinfo 2012-04-09 15:55:31 PDT
Bsmedberg: will you be able to do this landing to aurora in the next day or can we get someone else to land on your behalf?
Comment 13 Benjamin Smedberg [:bsmedberg] 2012-04-10 06:25:36 PDT
Comment 14 Simona B [:simonab ] 2012-05-08 08:45:49 PDT
Mozilla/5.0 (Windows NT 5.1; rv:13.0) Gecko/20100101 Firefox/13.0

Verified with Firefox 13 beta 2 on Windows XP that flash loads properly - used the STR from the Description.
Comment 15 Simona B [:simonab ] 2012-06-19 02:42:39 PDT
Mozilla/5.0 (Windows NT 5.1; rv:14.0) Gecko/20100101 Firefox/14.0

Verified with Firefox 14 beta 7 on Windows XP that flash loads properly - used the STR from the Description.

Note You need to log in before you can comment on or make changes to this bug.