Skip to content
Snippets Groups Projects

graphics: Do not load JSON ICDs multiple times from the same dirs

Merged Ludovico de Nittis requested to merge wip/fix_duplicate_icds into master
All threads resolved!

When we build the search paths for the JSON ICDs it might happen to have the same directory multiple times. For example if we have "XDG_CONFIG_DIRS=/usr/share" and "XDG_DATA_DIRS=/usr/share" we will look in "/usr/share" two times and duplicate all the JSONs that we find.

Usually this is not an issue but with some games, e.g. Red Dead Redemption 2, this can cause a crash at startup https://github.com/ValveSoftware/steam-runtime/issues/336

With this commit we filter out the directories that we already visited to prevent this kind of issues.

Fixes: #48


/cc @smcv

Edited by Ludovico de Nittis

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • added 1 commit

    • fa764426 - graphics: Do not load JSON ICDs multiple times from the same dirs

    Compare with previous version

  • Ludovico de Nittis resolved all threads

    resolved all threads

  • Simon McVittie approved this merge request

    approved this merge request

  • Simon McVittie mentioned in commit 736ee26e

    mentioned in commit 736ee26e

  • Please register or sign in to reply
    Loading