[kernel] Remove unnecessary string copy

This commit is contained in:
Joel Linn
2022-02-24 22:38:55 +01:00
committed by Rick Gibbed
parent b625ef0a38
commit 38d589d1e0
5 changed files with 14 additions and 15 deletions

View File

@@ -172,7 +172,7 @@ void XObject::SetAttributes(uint32_t obj_attributes_ptr) {
memory(), xe::load_and_swap<uint32_t>(
memory()->TranslateVirtual(obj_attributes_ptr + 4)));
if (!name.empty()) {
name_ = std::move(name);
name_ = std::string(name);
kernel_state_->object_table()->AddNameMapping(name_, handles_[0]);
}
}