use unique_lock instead of mutex::lock
this makes no sense, remove it