Closed Bug 333737 Opened 18 years ago Closed 18 years ago

Crash in SendMouseEvent()

Categories

(Core :: Widget: Cocoa, defect)

PowerPC
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: hwaara, Assigned: jaas)

Details

(Keywords: crash)

Attachments

(2 files)

I've been crashing every day with this stack. I don't know what is involved in reproducing it. This time I added a bookmark. The other time I was just mousing over something.

It's in the path that was recently changed to fix mouse over/out/enter events, so filing just to track it...

Thread 0 Crashed:
0   libwidget_mac.dylib   	0x192f2dfc SendMouseEvent(int, unsigned, nsIWidget*, nsMouseEvent::reasonType, _NSPoint*, nsChildView*) + 124 (nsChildView.mm:2711)
1   libwidget_mac.dylib   	0x192f32f0 -[ChildView mouseExited:] + 336 (nsChildView.mm:2762)
2   libwidget_mac.dylib   	0x192f30a4 -[ChildView mouseEntered:] + 596 (nsChildView.mm:2738)
3   com.apple.AppKit      	0x9377d5c0 -[NSWindow sendEvent:] + 6424
4   com.apple.AppKit      	0x93725ef4 -[NSApplication sendEvent:] + 4172
5   com.apple.AppKit      	0x9371d330 -[NSApplication run] + 508
6   libwidget_mac.dylib   	0x192e996c nsAppShellCocoa::Run() + 68 (nsAppShellCocoa.mm:129)
7   libtoolkitcomps.dylib 	0x19c87d54 nsAppStartup::Run() + 220 (nsAppStartup.cpp:161)
8   XUL                   	0x00210564 XRE_main + 8768 (nsAppRunner.cpp:2364)
9   org.mozilla.firefox   	0x00002c78 main + 56 (nsBrowserApp.cpp:61)
10  org.mozilla.firefox   	0x00002498 _start + 340 (crt.c:272)
11  org.mozilla.firefox   	0x00002340 start + 60
Attached patch fix v1.0Splinter Review
This will probably fix the problem, but it would be nice to have more info. Why the crash? I assume it is something like this:

Exception:  EXC_BAD_ACCESS (0x0001)
Codes:      KERN_PROTECTION_FAILURE (0x0002) at 0x00000000

Please copy those lines from your crash log.
hwaara - since you're a coder you might be able to get me even more info... can you repro this in gdb and tell me which argument is null?
Attachment #218187 - Flags: review?(hwaara)
Comment on attachment 218187 [details] [diff] [review]
fix v1.0

Let's fix the crash.  However, we probably should be on the look-out so this is not some deeper issue (e.g., a nested mouseout/mouseenter case we forgot about, or something like that.)
Attachment #218187 - Flags: review?(hwaara) → review+
For reference, here are two stacks that shows this crash.
It probably isn't a deeper issue we need to worry about. It is probably bad timing between the OS event and widget destruction, or a spurious OS event, something like that. It doesn't matter much if SendMouseEvent fails in cases like this. If a caller ever cares they can check the return value.
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: