mirror of
https://github.com/loot/libloot.git
synced 2026-07-27 14:16:01 -07:00
Fix crash when choosing empty message content.
This commit is contained in:
@@ -66,7 +66,9 @@ namespace loot {
|
||||
|
||||
MessageContent Message::ChooseContent(const unsigned int language) const {
|
||||
BOOST_LOG_TRIVIAL(trace) << "Choosing message content.";
|
||||
if (_content.size() == 1 || language == Language::any)
|
||||
if (_content.empty())
|
||||
return MessageContent();
|
||||
else if (_content.size() == 1 || language == Language::any)
|
||||
return _content[0];
|
||||
else {
|
||||
MessageContent english, match;
|
||||
|
||||
Reference in New Issue
Block a user