Skip to content

Path.js throws away one character paths. #26911

@mdavis199

Description

@mdavis199
  • Version:
    Master version in github
  • Platform:
    Windows
  • Subsystem:

The code to parse win32 paths, throws away paths that consist of one letter or character (unless its a forward or backward slash). Line 833 in the excerpt below, returns empty strings.

node/lib/path.js

Lines 826 to 833 in d989e20

if (len === 1) {
if (isPathSeparator(code)) {
// `path` contains just a path separator, exit early to avoid
// unnecessary work
ret.root = ret.dir = path;
return ret;
}
return ret;

Metadata

Metadata

Assignees

Labels

confirmed-bugIssues with confirmed bugs.pathIssues and PRs related to the path subsystem.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions