aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2017-04-09 10:41:27 +0200
committerMister Oyster <oysterized@gmail.com>2017-07-04 11:51:08 +0200
commit2f12297bdf445b04766ff63ac67ec171e4979438 (patch)
tree063ae35807bfd7d9eae82ef19cbceed2deee6bd1 /scripts
parent2e4bc6ff3d792d0dbac771f04fb95f023de2eae2 (diff)
ALSA: seq: Don't break snd_use_lock_sync() loop by timeout
commit 4e7655fd4f47c23e5249ea260dc802f909a64611 upstream. The snd_use_lock_sync() (thus its implementation snd_use_lock_sync_helper()) has the 5 seconds timeout to break out of the sync loop. It was introduced from the beginning, just to be "safer", in terms of avoiding the stupid bugs. However, as Ben Hutchings suggested, this timeout rather introduces a potential leak or use-after-free that was apparently fixed by the commit 2d7d54002e39 ("ALSA: seq: Fix race during FIFO resize"): for example, snd_seq_fifo_event_in() -> snd_seq_event_dup() -> copy_from_user() could block for a long time, and snd_use_lock_sync() goes timeout and still leaves the cell at releasing the pool. For fixing such a problem, we remove the break by the timeout while still keeping the warning. Suggested-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Willy Tarreau <w@1wt.eu>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions