mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-21 10:42:07 +00:00
Fix #586 segfault: Update the charmaps hashmap when an existing charmap is resized
This commit is contained in:
@@ -173,6 +173,7 @@ void charmap_Add(char *mapping, uint8_t value)
|
||||
if (currentCharmap->usedNodes == currentCharmap->capacity) {
|
||||
currentCharmap->capacity *= 2;
|
||||
currentCharmap = resizeCharmap(currentCharmap, currentCharmap->capacity);
|
||||
hash_ReplaceElement(charmaps, currentCharmap->name, currentCharmap);
|
||||
}
|
||||
|
||||
/* Switch to and init new node */
|
||||
|
||||
Reference in New Issue
Block a user