LogWindow: Use emplace instead of push for the message queue
Same thing.
This commit is contained in:
1 parent
a7b19e23b3
commit
d8f72e9cda
1 file changed
+1
-1
@@ -355,5 +355,5 @@ void CLogWindow::Log(LogTypes::LOG_LEVELS level, const char* text)
|
|||||||
if (msgQueue.size() >= MSGQUEUE_MAX_SIZE)
|
if (msgQueue.size() >= MSGQUEUE_MAX_SIZE)
|
||||||
msgQueue.pop();
|
msgQueue.pop();
|
||||||
|
|
||||||
msgQueue.push(std::make_pair(u8(level), StrToWxStr(text)));
|
msgQueue.emplace(static_cast<u8>(level), StrToWxStr(text));
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user