Right-clicking on flash applets hangs/crashes plugin-container/Firefox

RESOLVED FIXED

Status

()

Core
Plug-ins
--
blocker
RESOLVED FIXED
8 years ago
7 years ago

People

(Reporter: Joe Drew (not getting mail), Assigned: BenWa)

Tracking

({testcase})

unspecified
x86
Mac OS X
testcase
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(blocking2.0 final+)

Details

Attachments

(2 attachments, 1 obsolete attachment)

(Reporter)

Description

8 years ago
Created attachment 441174 [details]
complete test case

This might be for all flash applets, but it definitely applies to the testcase I've just attached. If you right-click on either of the flash applets in this testcase, Firefox hangs for ~30-ish seconds, then kills the plugin process, making me think that the plugin process has hung. Benoit tells me that without OOPP, right-clicking can crash or hang your browser.

OS X 10.6, Flash plugin 10.1 rc.

Updated

8 years ago
Blocks: 478976
Sounds like something we need to deal with before we release Mac OOPP to the masses. Josh, should you own this? If not, please reassign appropriately.
Assignee: nobody → joshmoz
blocking2.0: ? → final+
(Assignee)

Comment 2

8 years ago
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.3a5pre) Gecko/20100518 Minefield/3.7a5pre

I retested with a recent nightly. The right-click menu works fine without OOPP. I no longer get a hang or a crash with OOPP but the right-click menu does not work. I wonder if the right-click menu doesn't show up because it's being created from a separate process. We have a similar problem with flash fullscreen not being able to hide the dock.
(Assignee)

Comment 3

8 years ago
Disregard my previous comment, my test setup was likely incorrect.

I retested and I am seeing a crash for IP and no context menu for OOP. This is because 'NPAPI_ShowCocoaContextMenu' has a bug for IP and is not implemented OOP.

I am posting a patch because this code should have catch objective-c exception. The crash is caused by the following exception:
2010-05-31 12:02:41.162 firefox-bin[47638:903] Mozilla has caught an Obj-C exception [NSInternalInconsistencyException: Invalid parameter not satisfying: NSEventMaskFromType(type) & (MouseMask|NSMouseMovedMask)]
2010-05-31 12:02:41.311 firefox-bin[47638:903] *** Assertion failure in +[NSEvent mouseEventWithType:location:modifierFlags:timestamp:windowNumber:context:eventNumber:clickCount:pressure:], /SourceCache/AppKit/AppKit-1038.29/AppKit.subproj/NSEvent.m:477
Blocks: 568513
(Assignee)

Comment 4

8 years ago
Created attachment 448382 [details] [diff] [review]
Catch Objective-C Exception

This doesn't fix right-click menu but it stops the crash for now.
Attachment #448382 - Flags: review?(joshmoz)
(Assignee)

Updated

8 years ago
Attachment #448382 - Attachment is patch: true
Attachment #448382 - Attachment mime type: application/octet-stream → text/plain

Updated

8 years ago
Assignee: joshmoz → b56girard

Comment 5

8 years ago
"'NPAPI_ShowCocoaContextMenu' has a bug for IP"

What is the bug? Do you know what we're doing to trigger this exception?

Comment 6

8 years ago
Comment on attachment 448382 [details] [diff] [review]
Catch Objective-C Exception

+  NS_OBJC_END_TRY_ABORT_BLOCK_RETURN(PR_TRUE);

The return type for the function is NPError.
Attachment #448382 - Flags: review?(joshmoz) → review-
(Assignee)

Comment 7

8 years ago
Created attachment 449464 [details] [diff] [review]
Catch Objective-C Exception v2

Changed the return to NPERR_GENERIC_ERROR.
Attachment #448382 - Attachment is obsolete: true
Attachment #449464 - Flags: review?(joshmoz)

Comment 8

8 years ago
Comment on attachment 449464 [details] [diff] [review]
Catch Objective-C Exception v2

+  NS_OBJC_END_TRY_ABORT_BLOCK_RETURN(NPERR_GENERIC_ERROR);

Put a newline before this.
Attachment #449464 - Flags: review?(joshmoz) → review+
(Assignee)

Comment 9

8 years ago
Pushed to mozilla-central:
http://hg.mozilla.org/mozilla-central/rev/82169be6b34d

We need to try the STR to see if the right-click context menu works correctly now. I've seen this issue on and off so if someone else could verify the right click menu work for them in-process that would be great.
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → FIXED
(Assignee)

Updated

7 years ago
Blocks: 583356
You need to log in before you can comment on or make changes to this bug.