XUser: a gamertag without a suffix has an empty modern suffix #229
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory!229
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/229/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@Dufftwt on GitHub · 2026-11-24 01:38 UTC · original
Dufftwt:fix/gamertag-modern-suffix-empty→main· +29 −3 · 1 files · 1 commits · merged 2026-11-24 07:57 UTCWhat's wrong
XUserGetGamertagtakes a component,XUserGamertagComponent:ClassicModernModernSuffixUniqueModernOur user, "Player", has no suffix.
get_gamertagignores the component and returns"Player"for all four, including the suffix. A title that shows the suffix whenever it isn't empty (name#suffix, the usual way to display a modern gamertag) shows:What the fix does
get_gamertagreturns an empty string (just the NUL,used= 1) forModernSuffix(2), and the name for every other component, as before.How it behaves after the fix
The user shows as
Player. The classic, modern and unique modern components are stillPlayer, and the suffix is empty, as for any account without a suffix. Both slots that reachget_gamertag, the gamertag interface's and the older one on the user interface, give the same result.Tests
The new test
a_gamertag_without_a_suffix_has_an_empty_modern_suffixreads all four components through both slots. It expectsPlayer\0for 0, 1 and 3, and\0for 2.I ran
cargo test --workspaceon GitHub'swindows-latestwith Rust 1.98.1 fromrust-toolchain.toml:victory-hlehas 87 passed, the other crates have 0 failed.main: it fails on the suffix:left: [80, 108, 97, 121, 101, 114, 0]("Player\0"),right: [0].--test-threads=1. With 4 threads, the shader crate's GPU tests sometimes crash on that runner (STATUS_ACCESS_VIOLATION), on unmodifiedmainas well.Not tested: how the title displays the name.
@jeremygold02 on GitHub · 2026-11-24 05:27 UTC · original
Thanks @Dufftwt for covering the modern gamertag suffix when the tag has no suffix.
I tested commit
d46b07803c80c6f05ae1738254ec98c7d50529a9with:The targeted test passed (1 passed, 0 failed; 86 filtered).
a_gamertag_without_a_suffix_has_an_empty_modern_suffixchecks classic, modern, modern-suffix, and unique-modern components through both gamertag interface slots. The ordinary components returnPlayer; the modern suffix returns an empty NUL-terminated string.This exercises the HLE interface with its default user fixture; it does not use a real account or online profile.