Assorted string fixes, mostly for consistency.

This commit is contained in:
OBattler
2024-11-10 02:23:21 +01:00
parent a3ad407a21
commit 55b091fb58
13 changed files with 31 additions and 23 deletions

View File

@@ -103,6 +103,14 @@ device_set_context(device_context_t *c, const device_t *dev, int inst)
void * single_sec = config_find_section((char *) dev->name);
if ((sec == NULL) && (single_sec != NULL))
config_rename_section(single_sec, c->name);
} else if (!strcmp(dev->name, "PS/2 Mouse")) {
sprintf(c->name, "%s", dev->name);
/* Migrate the old "Standard PS/2 Mouse" section */
const void *sec = config_find_section(c->name);
void * old_sec = config_find_section("Standard PS/2 Mouse");
if ((sec == NULL) && (old_sec != NULL))
config_rename_section(old_sec, c->name);
} else
sprintf(c->name, "%s", dev->name);
}