Closed Bug 458108 Opened 16 years ago Closed 16 years ago

Prism crashes Firefox Trunk when downloading a file [NS_ERROR_XPC_JSOBJECT_HAS_NO_FUNCTION_NAMED] [@ nsJAR::Open(nsIFile*) ]

Categories

(Mozilla Labs :: Prism, defect)

x86
Windows NT
defect
Not set
critical

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: fehe, Assigned: mfinkle)

References

Details

(Keywords: crash)

Crash Data

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1b1pre) Gecko/20081001 Firefox/2.0.0.11
Build Identifier: 0.2.1

If Prism is used with the 20081001 Firefox Trunk, the browser is crashed whenever saving a file.  The following exception is generated just before the crash:

Error: 'JavaScript component does not have a method named: "onDownloadStateChange"' when calling method: [nsIDownloadProgressListener::onDownloadStateChange] = NS_ERROR_XPC_JSOBJECT_HAS_NO_FUNCTION_NAMED

Breakpad IDS:
http://crash-stats.mozilla.com/report/index/720efa61-8fd6-11dd-86e0-001cc45a2c28
http://crash-stats.mozilla.com/report/index/0f21df78-8fd6-11dd-a188-001cc45a2c28

Browser Build ID: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1b1pre) Gecko/20081001

Reproducible: Always

Steps to Reproduce:
1. Install the lastest Firefox 3.1 Trunk (tested on Win XP SP3)
2. Start Firefox and go to Tools --> Options... --> Main
3. Select "Always ask me where to save files."  Click OK
4. Open Error Console and make sure logging of "Errors" is enabled
5. Install Prism for Firefox 0.2.1
6. Visit http://fileforum.betanews.com/detail/Sysinternals_Suite/1194884530/1
7. Click the "Download Now" link and save the file someplace other than Desktop
8. Note the exception in Error Console
9. Firefox Crashes
Well, this might be a Prism bug, because it somehow allows to pass a null argument to pass to the zip-reader open method, but that function still should not crash when a null argument is passed, so I filed bug 458158 for that.
http://crash-stats.mozilla.com/report/index/176b39e8-9017-11dd-80cf-001a4bd43ef6

Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.1b2pre) Gecko/20081008 Minefield/3.1b2pre ID:20081008032217
Could have sworn we knew about this. I remember discussing the nsJAR:Open() issue with someone a while back. Anyway, I agree: the problem is both Prism (shouldn't pass in NULL) and Firefox (should check the parameter, not just crash).
Depends on: 458158
Flags: blocking1.0?
Keywords: crash
Summary: Crashes 20081001 Firefox Trunk, mercilessly, when downloading a file [NS_ERROR_XPC_JSOBJECT_HAS_NO_FUNCTION_NAMED] [@ nsJAR::Open(nsIFile*) ] → Prism crashes Firefox Trunk when downloading a file [NS_ERROR_XPC_JSOBJECT_HAS_NO_FUNCTION_NAMED] [@ nsJAR::Open(nsIFile*) ]
I hit this with 100% reproducibility on a trunk Windows build with refractor installed.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Attached patch patchSplinter Review
This patch adds some checks to refractor-overlay.js to keep a null file from being passed to WebAppInstall.install(file)

The patch also adds onDownloadStateChange, which keeps the error from appearing in the console. This part seemed unrelated to the crash.
Assignee: nobody → mark.finkle
Attachment #353948 - Flags: review?(matthew.gertner)
Confirm the crashes even if you try to save a Images as ..... with 3.1 Beta 2
Comment on attachment 353948 [details] [diff] [review]
patch

I can't for the life of me remember who I discussed this with, but you might want to check with someone on the Firefox side as well since I don't think it should crash even if you pass in a NULL pointer.
Attachment #353948 - Flags: review?(matthew.gertner) → review+
(In reply to comment #8)
> (From update of attachment 353948 [details] [diff] [review])
> I can't for the life of me remember who I discussed this with, but you might
> want to check with someone on the Firefox side as well since I don't think it
> should crash even if you pass in a NULL pointer.

bug 458158
Modified: mozilla-code\mozilla-prism\mozilla\prism\extension\chrome\content\refractor-overlay.js  
Sending content: mozilla-code\mozilla-prism\mozilla\prism\extension\chrome\content\refractor-overlay.js  
Completed: At revision: 21373
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
So does this mean the next Prism build will not longer crash Firefox, in spite of the bug 458158 being moribund?
(In reply to comment #11)
> So does this mean the next Prism build will not longer crash Firefox, in spite
> of the bug 458158 being moribund?

Correct
Crash Signature: [@ nsJAR::Open(nsIFile*) ]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: