Fix two GCC 11 warnings: Unneeded copies.

std::move created an unneeded copy.
iterating without reference also created copies.
This commit is contained in:
Markus Wick 2021-05-29 08:55:37 +02:00
parent 95b988ece3
commit 9f92beed0a
2 changed files with 3 additions and 3 deletions

View file

@ -258,7 +258,7 @@ struct KernelCore::Impl {
KAutoObject::Create(thread.get());
ASSERT(KThread::InitializeDummyThread(thread.get()).IsSuccess());
thread->SetName(fmt::format("DummyThread:{}", GetHostThreadId()));
return std::move(thread);
return thread;
};
thread_local auto thread = make_thread();