output/Internal: remember the most recent error
This commit is contained in:
@@ -29,6 +29,8 @@
|
||||
#include "thread/Thread.hxx"
|
||||
#include "system/PeriodClock.hxx"
|
||||
|
||||
#include <exception>
|
||||
|
||||
class PreparedFilter;
|
||||
class MusicPipe;
|
||||
class EventLoop;
|
||||
@@ -255,6 +257,14 @@ struct AudioOutput {
|
||||
*/
|
||||
AudioOutputSource source;
|
||||
|
||||
/**
|
||||
* The error that occurred in the output thread. It is
|
||||
* cleared whenever the output is opened successfully.
|
||||
*
|
||||
* Protected by #mutex.
|
||||
*/
|
||||
std::exception_ptr last_error;
|
||||
|
||||
/**
|
||||
* Throws #std::runtime_error on error.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user