Fixes a crash in the csv2yaml tool (#6141)
This commit is contained in:
parent
6f4fc838c9
commit
efd66000f6
@ -2957,7 +2957,7 @@ static bool itemdb_read_randomopt_group(char* str[], int columns, int current) {
|
|||||||
if (group != nullptr)
|
if (group != nullptr)
|
||||||
entries = group->slots[j];
|
entries = group->slots[j];
|
||||||
|
|
||||||
std::shared_ptr<s_random_opt_group_entry> entry;
|
std::shared_ptr<s_random_opt_group_entry> entry = std::make_shared<s_random_opt_group_entry>();
|
||||||
|
|
||||||
entry->id = static_cast<uint16>(randid_tmp);
|
entry->id = static_cast<uint16>(randid_tmp);
|
||||||
entry->min_value = (int16)strtoul(str[k + 1], nullptr, 10);
|
entry->min_value = (int16)strtoul(str[k + 1], nullptr, 10);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user