Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PathStrings.Normalize("../../foo") is broken #60

Closed
ForNeVeR opened this issue May 25, 2024 · 0 comments · Fixed by #61
Closed

PathStrings.Normalize("../../foo") is broken #60

ForNeVeR opened this issue May 25, 2024 · 0 comments · Fixed by #61
Assignees
Labels
bug Something isn't working

Comments

@ForNeVeR
Copy link
Owner

PathStrings.Normalize is currently broken for certain non-normalized strings (starting from ..).

It supports ../foo, but when it sees ../../, it thinks it should go one level up from ../ which is an empty path.

So, an even number of .. gives an empty path, and an odd number of .. gives one ...

New broken tests:

    [InlineData("../../foo", "../../foo")]
    [InlineData("../../../foo", "../../../foo")]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant