output/Plugin: remove 'Error&' parameters, use C++ exceptions only

This commit is contained in:
Max Kellermann
2016-11-09 11:56:01 +01:00
parent 445e82be75
commit d9cb85df83
34 changed files with 198 additions and 364 deletions

View File

@@ -21,7 +21,6 @@
#include "Control.hxx"
#include "Idle.hxx"
#include "DetachedSong.hxx"
#include "util/Error.hxx"
#include <algorithm>
@@ -171,15 +170,6 @@ PlayerControl::SetError(PlayerError type, std::exception_ptr &&_error)
error = std::move(_error);
}
void
PlayerControl::SetError(PlayerError type, Error &&_error)
{
assert(type != PlayerError::NONE);
assert(_error.IsDefined());
SetError(type, std::make_exception_ptr(std::move(_error)));
}
void
PlayerControl::LockClearError()
{

View File

@@ -355,9 +355,7 @@ public:
* Caller must lock the object.
*
* @param type the error type; must not be #PlayerError::NONE
* @param error detailed error information; must be defined.
*/
void SetError(PlayerError type, Error &&error);
void SetError(PlayerError type, std::exception_ptr &&_error);
/**

View File

@@ -33,7 +33,6 @@
#include "tag/Tag.hxx"
#include "Idle.hxx"
#include "util/Domain.hxx"
#include "util/Error.hxx"
#include "thread/Name.hxx"
#include "Log.hxx"