DescriptionFix possible multiple calls to MidiManager::StartInitialization() in StartSession()
We assume the caller is the first client and call StartInitialization() if
|pending_clients_| is empty, however |pending_clients_| may be cleared before
initialization finishes and cause successive StartSession() calls to call
StartInitialization() again. This leads to unwanted behavior depending on
platform-specific implementation.
Now we use an enum field to track initialization state, and flatten logic in
StartSession() to make things simple.
BUG=658662
Committed: https://crrev.com/a25e7a3d87a75cd00cc849f41a7ef9261a2e18d4
Cr-Commit-Position: refs/heads/master@{#427047}
Patch Set 1 #Patch Set 2 : comment #
Total comments: 4
Patch Set 3 : styles #
Messages
Total messages: 10 (4 generated)
|