Closed Bug 265544 Opened 21 years ago Closed 19 years ago

PL_PostEvent/nsEventQueueImpl::PostEvent error handling is odd

Categories

(Core :: XPCOM, defect)

defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: dbaron, Assigned: dougt)

Details

The error handling in nsEventQueueImpl::PostEvent (some of which comes from PL_PostEvent) is odd. In particular, it can return failure even when the event is added to the queue. Many clients assume that failure means the event should be deleted. The particular failure case I'm worried about is if _pl_NativeNotify fails in PL_PostEvent. This happens after the event is added to the event queue (so basically ownership has been transferred). Either PL_PostEvent should not propagate this error or nsEventQueueImpl::PostEvent should not propagate the error from PL_PostEvent (and should check the one other case where it can return an error).
ouch
PL_PostEvent/nsEventQueueImpl no longer exist. See bug 326273.
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.