Merge pull request #9763 from L-as/avoid-unnecessary-copy

Avoid unnecessary copy of goal log

(cherry picked from commit 268c49264a)
Change-Id: I5d9de9e43a7ddcb09d25bbc7367c9d83f58c7a75
This commit is contained in:
eldritch horrors 2024-03-04 08:01:03 +01:00
parent e310bbf913
commit 64b077cdaa

View file

@ -448,7 +448,7 @@ void Worker::waitForInput()
} else {
printMsg(lvlVomit, "%1%: read %2% bytes",
goal->getName(), rd);
std::string data((char *) buffer.data(), rd);
std::string_view data((char *) buffer.data(), rd);
j->lastOutput = after;
goal->handleChildOutput(k, data);
}