From 35ab11cbb69b5bc78b374f1ce7bde82fb1b6dff1 Mon Sep 17 00:00:00 2001 From: David Mott Date: Fri, 26 Apr 2019 04:46:46 -0500 Subject: [PATCH] remove std::auto_ptr --- utils/threadpool/threadpool.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/utils/threadpool/threadpool.h b/utils/threadpool/threadpool.h index 84c9aff7a..16754385d 100644 --- a/utils/threadpool/threadpool.h +++ b/utils/threadpool/threadpool.h @@ -75,9 +75,8 @@ public: boost::thread* create_thread(F threadfunc) { boost::lock_guard guard(m); - std::auto_ptr new_thread(new boost::thread(threadfunc)); - threads.push_back(new_thread.get()); - return new_thread.release(); + threads.push_back(new boost::thread(threadfunc)); + return threads.back(); } void add_thread(boost::thread* thrd)