Closed Bug 1149619 Opened 9 years ago Closed 9 years ago

Possible race condition in Dispatcher#quitApplication

Categories

(Remote Protocol :: Marionette, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INVALID

People

(Reporter: ato, Assigned: ato)

Details

(Keywords: pi-marionette-server)

Attachments

(1 obsolete file)

In Dispatcher#quitApplication, the closeSignal_ callback to shut down MarionetteServer (and its connections) is called before sendOk.  This seems to work fine, but is a potential race condition.

They should be switched, so that we first send the response and then clean up the connections.
Assignee: nobody → ato
Status: NEW → ASSIGNED
Attached file MozReview Request: bz://1149619/ato (obsolete) —
/r/6363 - Bug 1149619: Fix race in Dispatcher#quitApplication

Pull down this commit:

hg pull review -r 9ba66035a81f1638e7884b129cef05d4eb272c9b
Attachment #8586184 - Flags: review?(dburns)
Examining MarionetteServer#stop it's clear that it only closes the _listener_, and doesn't end any existing socket connections.  Therefore the current behaviour is correct.

Thanks for :chmanchester for noticing!
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → INVALID
Attachment #8586184 - Attachment is obsolete: true
Attachment #8586184 - Flags: review?(dburns)
Product: Testing → Remote Protocol
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: