Closed Bug 1156057 Opened 9 years ago Closed 9 years ago

Right-clicking an image throws an error

Categories

(Core Graveyard :: File Handling, defect)

x86_64
Windows 8.1
defect
Not set
normal

Tracking

(e10sm6+, firefox40 fixed)

RESOLVED FIXED
mozilla40
Tracking Status
e10s m6+ ---
firefox40 --- fixed

People

(Reporter: elbart, Assigned: jimm)

References

Details

Attachments

(1 file, 3 obsolete files)

Right-clicking an image throws this error:

[Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIProperties.get]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: chrome://browser/content/content.js :: handleContentContextMenu :: line 110"  data: no] content.js:113:

Happens with e10s on and off.


Regression-range:

m-c:

Last good revision: 8af276ab8636 (2015-03-31)
First bad revision: 37ddc5e2eb72 (2015-04-01)
Pushlog:
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=8af276ab8636&tochange=37ddc5e2eb72


m-i:

Last good revision: ab01fd91bc02
First bad revision: 870046adb53a
Pushlog:
https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=ab01fd91bc02&tochange=870046adb53a


fx-team:

Last good revision: 18a8ea7c2c62
First bad revision: 049a2ddcc904
Pushlog:
https://hg.mozilla.org/integration/fx-team/pushloghtml?fromchange=18a8ea7c2c62&tochange=049a2ddcc904


acd77f938db4	Jim Mathies — Bug 1122525 - On right-click query in advance media related information from the image cache and forward this info to chrome with the contextmenu event. r=mconley
Blocks: 1122525
This error is passive. It's occurring on the content disposition line, which I guess isn't widely supported anymore.

http://stackoverflow.com/questions/1012437/uses-of-content-disposition-in-an-http-response-header

We can take the report error line out.

http://mxr.mozilla.org/mozilla-central/source/browser/base/content/content.js#110
Status: UNCONFIRMED → NEW
tracking-e10s: --- → ?
Ever confirmed: true
Assignee: nobody → jmathies
Attached patch patch (obsolete) — Splinter Review
Comment on attachment 8595959 [details] [diff] [review]
patch

I guess trying to get both with individual try/catch blocks might be best.
Attachment #8595959 - Flags: review?(felipc)
Comment on attachment 8595959 [details] [diff] [review]
patch

Review of attachment 8595959 [details] [diff] [review]:
-----------------------------------------------------------------

::: browser/base/content/content.js
@@ +103,5 @@
> +    let imageCache =
> +      Cc["@mozilla.org/image/tools;1"].getService(Ci.imgITools)
> +                                      .getImgCacheForDocument(doc);
> +    let props =
> +      imageCache.findEntryProperties(event.target.currentURI);

AFAICT, this can't throw - 
http://mxr.mozilla.org/mozilla-central/source/image/src/imgLoader.cpp#1346
Attachment #8595959 - Flags: review?(felipc) → review+
Attached patch patch (r=felipe) (obsolete) — Splinter Review
thanks!
Attachment #8595959 - Attachment is obsolete: true
Attached patch patch (r=felipe) (obsolete) — Splinter Review
I was looking this over one last time and noticed that getImgCacheForDocument can throw so I had to bring back the main try block. Tested locally everything works fine.
Attachment #8596618 - Attachment is obsolete: true
Attachment #8596628 - Flags: review?(felipc)
Attached patch patch (r=felipe)Splinter Review
sorry, wrong patch.
Attachment #8596628 - Attachment is obsolete: true
Attachment #8596628 - Flags: review?(felipc)
Attachment #8596629 - Flags: review?(felipc)
Attachment #8596629 - Flags: review?(felipc) → review+
See Also: → 1160500
https://hg.mozilla.org/mozilla-central/rev/e1d007ba6321
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla40
QA Whiteboard: [good first verify]
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.