Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1320)

Unified Diff: media/midi/midi_manager.cc

Issue 1510313002: Fix crash with MIDI send for MidiManagerAlsa (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2526
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | media/midi/midi_manager_alsa.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/midi/midi_manager.cc
diff --git a/media/midi/midi_manager.cc b/media/midi/midi_manager.cc
index 6e8c1a266fa86502407d929db218eb1e85afc1f5..27fe9c6eb21b668971ea659e61650005d4fb9f54 100644
--- a/media/midi/midi_manager.cc
+++ b/media/midi/midi_manager.cc
@@ -134,11 +134,10 @@ void MidiManager::EndSession(MidiManagerClient* client) {
}
void MidiManager::AccumulateMidiBytesSent(MidiManagerClient* client, size_t n) {
- {
- base::AutoLock auto_lock(lock_);
- if (clients_.find(client) == clients_.end())
- return;
- }
+ base::AutoLock auto_lock(lock_);
+ if (clients_.find(client) == clients_.end())
+ return;
+
client->AccumulateMidiBytesSent(n);
}
« no previous file with comments | « no previous file | media/midi/midi_manager_alsa.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698