Skip to content

fix: Game Tracker truncating names containing dots - #722

Open
ericreinsmidt wants to merge 1 commit into
LoveRetro:mainfrom
ericreinsmidt:fix/game-tracker-double-extension-strip
Open

fix: Game Tracker truncating names containing dots#722
ericreinsmidt wants to merge 1 commit into
LoveRetro:mainfrom
ericreinsmidt:fix/game-tracker-double-extension-strip

Conversation

@ericreinsmidt

@ericreinsmidt ericreinsmidt commented May 15, 2026

Copy link
Copy Markdown

Summary

  • cleanName() called removeExtension() on game names already stored in the DB without file extensions
  • This caused names with dots like "Gun.Smoke" to be truncated to "Gun" in Game Tracker
  • Fix: remove the redundant removeExtension() call from cleanName()

This is an extremely rare case with ROMs released by No-Intro — Gun.Smoke (USA).nes may literally be the only one — but could come into play with homebrew games.

Test plan

  • Verify "Gun.Smoke" displays correctly in Game Tracker
  • Verify games without dots still display correctly

cleanName() called removeExtension() on names already stored in the DB
without extensions, causing names like "Gun.Smoke" to display as "Gun".
@ericreinsmidt
ericreinsmidt force-pushed the fix/game-tracker-double-extension-strip branch from e41d5d9 to 77aa9aa Compare May 19, 2026 03:24
lepht pushed a commit to lepht/nexterUI that referenced this pull request Aug 12, 2026
Adopted from upstream LoveRetro#722 by Eric Reinsmidt, taken while
upstream is still GPL-3.0 (see LoveRetro#765).

cleanName() ran removeExtension() over names the game time db already
stores without one, so the first dot in a title was read as a suffix
boundary. "Gun.Smoke" displayed as "Gun" and "Dr.Mario" as "Dr".

Both callers in this tree - gametime.c and gametimedb.c - pass rom->name,
which is stored extension-free, so dropping the removeExtension() call is
safe for every caller we have.

Covered in tests/test_utils.c: the two truncation cases fail without the
fix, alongside guards for the behaviour that has to survive it - numeric
sorting prefixes, underscores and region parens.

Co-Authored-By: Eric Reinsmidt <eric@reinsmidt.com>
lepht pushed a commit to lepht/nexterUI that referenced this pull request Aug 12, 2026
Adopted from upstream LoveRetro#722 by Eric Reinsmidt, taken while
upstream is still GPL-3.0 (see LoveRetro#765).

cleanName() ran removeExtension() over names the game time db already
stores without one, so the first dot in a title was read as a suffix
boundary. "Gun.Smoke" displayed as "Gun" and "Dr.Mario" as "Dr".

Both callers in this tree - gametime.c and gametimedb.c - pass rom->name,
which is stored extension-free, so dropping the removeExtension() call is
safe for every caller we have.

Covered in tests/test_utils.c: the two truncation cases fail without the
fix, alongside guards for the behaviour that has to survive it - numeric
sorting prefixes, underscores and region parens.

Co-Authored-By: Eric Reinsmidt <eric@reinsmidt.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant