path-unix: Only accept absolute paths - #12258
Merged
Merged
Conversation
linkmauve
force-pushed
the
absolute-paths
branch
from
August 26, 2023 14:19
4a7aedc to
1f6c65f
Compare
philipl
reviewed
Aug 26, 2023
philipl
left a comment
Member
There was a problem hiding this comment.
Should we log something so there's feedback?
Contributor
You can't (not without doing hacky shit) since |
N-R-K
suggested changes
Aug 26, 2023
|
|
||
| // Maintain compatibility with old ~/.mpv | ||
| if (home && home[0]) | ||
| if (home && home[0] == '/') |
Contributor
There was a problem hiding this comment.
This doesn't look right. $HOME is not part of XDG base dirs.
Same with all the other home[0] == '/' cases.
Contributor
Author
There was a problem hiding this comment.
Does that mean programs should happily accept a relative HOME?
(Sorry for having dropped the ball on this PR for two years, I’ll get back to it shortly.)
Edit: This is now fixed, we accept relative HOME again with this PR.
linkmauve
force-pushed
the
absolute-paths
branch
2 times, most recently
from
October 1, 2025 10:04
1a6bbbe to
dc904b7
Compare
Dudemanguy
requested changes
Jul 2, 2026
The XDG Base Directory specification says “All paths set in these environment variables must be absolute. If an implementation encounters a relative path in any of these variables it should consider the path invalid and ignore it.”
Contributor
Author
|
There, I changed that in |
Dudemanguy
approved these changes
Jul 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The XDG Base Directory specification says “All paths set in these environment variables must be absolute. If an implementation encounters a relative path in any of these variables it should consider the path invalid and ignore it.”