From: Andre Noll Date: Thu, 11 Jun 2020 13:28:49 +0000 (+0200) Subject: Avoid audiod hangs when prebuffer filter is active. X-Git-Tag: v0.6.3~17 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=1eeb434d731702fd5c0c85c62bf6d18dd3463d8a;hp=b3c68fd8519a426d6b6285dcb5a865670285e99a Avoid audiod hangs when prebuffer filter is active. This filter misses to honor task notifications. As a result of this omission, when CTRL+C is pressed while audiod is running in foreground mode and the prebuffer filter is active, the audiod process hangs. The fix is obvious. --- diff --git a/prebuffer_filter.c b/prebuffer_filter.c index ad237376..05ceb88c 100644 --- a/prebuffer_filter.c +++ b/prebuffer_filter.c @@ -57,7 +57,11 @@ static int prebuffer_post_select(__a_unused struct sched *s, void *context) size_t iqs = btr_get_input_queue_size(btrn); struct private_prebuffer_data *ppd = fn->private_data; uint32_t size = FILTER_CMD_OPT_UINT32_VAL(PREBUFFER, SIZE, fn->lpr); + int ret; + ret = task_get_notification(fn->task); + if (ret < 0) + return ret; if (ppd->barrier.tv_sec == 0) return 0; if (tv_diff(now, &ppd->barrier, NULL) < 0)