File tree 2 files changed +14
-0
lines changed
2 files changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ ver 0.20.7 (not yet released)
2
2
* database
3
3
- simple: fix false positive directory loop detection with NFS
4
4
* enforce a reasonable minimum audio_buffer_size setting
5
+ * cap buffer_before_play at 80% to prevent deadlock
5
6
* fix random crashes when compiled with clang
6
7
7
8
ver 0.20.6 (2017/03/10)
Original file line number Diff line number Diff line change @@ -340,6 +340,19 @@ initialize_decoder_and_player(const ReplayGainConfig &replay_gain_config)
340
340
" than 100 percent, line %i" ,
341
341
param->value .c_str (), param->line );
342
342
}
343
+
344
+ if (perc > 80 ) {
345
+ /* this upper limit should avoid deadlocks
346
+ which can occur because the DecoderThread
347
+ cannot ever fill the music buffer to
348
+ exactly 100%; a few chunks always need to
349
+ be available to generate silence in
350
+ Player::SendSilence() */
351
+ FormatError (config_domain,
352
+ " buffer_before_play is too large (%f%%), capping at 80%%; please fix your configuration" ,
353
+ perc);
354
+ perc = 80 ;
355
+ }
343
356
} else
344
357
perc = DEFAULT_BUFFER_BEFORE_PLAY;
345
358
You can’t perform that action at this time.
0 commit comments