* \note A stream must have been started when called.
*/
void (*flush)( audio_output_t *, bool wait);
- /**< Flushes or drains the playback buffers (optional, may be NULL).
+ /**< Flushes or drains the playback buffers (mandatoryl, cannot be NULL).
* \param wait true to wait for playback of pending buffers (drain),
* false to discard pending buffers (flush)
* \note A stream must have been started when called.
(void) aout;
}
+static void Flush(audio_output_t *aout, bool wait)
+{
+ (void) aout; (void) wait;
+}
+
static int Start(audio_output_t *aout, audio_sample_format_t *restrict fmt)
{
if (AOUT_FMT_SPDIF(fmt) && var_InheritBool(aout, "spdif"))
aout->time_get = NULL;
aout->play = Play;
aout->pause = NULL;
- aout->flush = NULL;
+ aout->flush = Flush;
aout->stop = NULL;
aout->volume_set = NULL;
aout->mute_set = NULL;
void aout_OutputFlush( audio_output_t *aout, bool wait )
{
aout_assert_locked( aout );
-
- if( aout->flush != NULL )
- aout->flush( aout, wait );
+ aout->flush (aout, wait);
}