From fc6d251be9000ec396e8f709fe6a9b3747209fcd Mon Sep 17 00:00:00 2001 From: sonninnos <45124675+sonninnos@users.noreply.github.com> Date: Tue, 23 Apr 2024 19:54:04 +0300 Subject: [PATCH] Fix save new config name when core loaded (#16458) --- command.c | 1 + 1 file changed, 1 insertion(+) diff --git a/command.c b/command.c index ffb1f02bc8..708c3cd29f 100644 --- a/command.c +++ b/command.c @@ -1778,6 +1778,7 @@ bool command_event_save_core_config( for (i = 0; i < 16; i++) { size_t _len = strlcpy(tmp, config_path, sizeof(tmp)); + if (i) _len += snprintf(tmp + _len, sizeof(tmp) - _len, "-%u", i); strlcpy(tmp + _len, ".cfg", sizeof(tmp) - _len);