Sound: Recover broken audio connection by closing and reopening the device

This commit is contained in:
Andreas Eversberg
2020-07-26 13:13:01 +02:00
parent ed72e29dbb
commit 8929b332cb
2 changed files with 75 additions and 51 deletions

View File

@@ -347,7 +347,7 @@ void process_sender_audio(sender_t *sender, int *quit, int latspl)
#endif
count = sender->audio_get_tosend(sender->audio, latspl);
if (count < 0) {
PDEBUG(DSENDER, DEBUG_ERROR, "Failed to get number of samples in buffer (rc = %d)!\n", count);
PDEBUG_CHAN(DSENDER, DEBUG_ERROR, "Failed to get number of samples in buffer (rc = %d)!\n", count);
if (count == -EPIPE) {
if (cant_recover) {
cant_recover: