MXS-2002 Replace auto_ptr with unique_ptr

Given 'Derived : public Base', a unique_ptr<Derived> converts
implictly to a unique_ptr<Base>.
This commit is contained in:
Johan Wikman
2018-08-09 11:12:32 +03:00
parent 9cfd451a1d
commit 6335d3776c
7 changed files with 14 additions and 26 deletions

View File

@ -207,13 +207,7 @@ public:
* directly without going through the message loop of the worker,
* otherwise the task is delivered via the message loop.
*/
static size_t broadcast(std::auto_ptr<DisposableTask> sTask);
template<class T>
static size_t broadcast(std::auto_ptr<T> sTask)
{
return broadcast(std::auto_ptr<DisposableTask>(sTask.release()));
}
static size_t broadcast(std::unique_ptr<DisposableTask> sTask);
/**
* Executes a task on all workers in serial mode (the task is executed