Skip to content

gh-127146: Emscripten: Fix pathlib glob_dotdot test #135624

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

hoodmane
Copy link
Contributor

@hoodmane hoodmane commented Jun 17, 2025

The Emscripten path resolver uses the same mechanism for resolving .. at a file system root as for resolving symlinks. This is because roots don't store their mountpoints. If the parent of a node is itself, it is a root but it might be a mountpoint in some other file system.

Anyways, if a path has enough ..'s at the root, it will return ELOOP. Enough turns out to be 49.

Upstream fix:
emscripten-core/emscripten#24591

The Emscripten path resolver uses the same mechanism for resolving ..
at a file system root as for resolving symlinks. This is because
roots don't store their mountpoints. If the parent of a node is itself,
it is a root but it might be a mountpoint in some other file system.

Anyways, if a path has enough ..'s at the root, it will return ELOOP.
Enough turns out to be 49.
@hoodmane hoodmane requested a review from barneygale as a code owner June 17, 2025 16:52
@bedevere-app bedevere-app bot added awaiting review tests Tests in the Lib/test dir labels Jun 17, 2025
@hoodmane hoodmane requested a review from freakboy3742 June 17, 2025 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting review skip news tests Tests in the Lib/test dir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant