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

path.win32.isAbsolute considers relative paths absolute #56766

Open
reverofevil opened this issue Jan 26, 2025 · 0 comments
Open

path.win32.isAbsolute considers relative paths absolute #56766

reverofevil opened this issue Jan 26, 2025 · 0 comments
Labels
path Issues and PRs related to the path subsystem.

Comments

@reverofevil
Copy link

Version

22.11.0

Platform

Linux pc 6.8.0-48-generic #48-Ubuntu SMP PREEMPT_DYNAMIC Fri Sep 27 14:04:52 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux

Subsystem

No response

What steps will reproduce the bug?

require('path').win32.isAbsolute('\\foo') === true

How often does it reproduce? Is there a required condition?

Yes. No.

What is the expected behavior? Why is that the expected behavior?

Here's a behavior of cd on Windows:

C:\Users\user> cd \Windows
C:\Windows>

\Windows is relative to drive name.

Expected output for isAbsolute() is false.

What do you see instead?

isAbsolute() is true.

Additional information

No response

@lpinca lpinca added the path Issues and PRs related to the path subsystem. label Jan 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
path Issues and PRs related to the path subsystem.
Projects
None yet
Development

No branches or pull requests

2 participants