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

A collection of fixes for Windows path handling, especially involving symlinks #1468

Merged

Conversation

marktucker
Copy link
Contributor

Description of Change(s)

This started as an attempt to fix a possible exception when handling paths starting with "/" in the code for #1441 and then write some additional tests. But my test cases kept failing. Turns out there were still issues in handling on non-mountpoint symlinks on Windows. There was also the potential for infinite recursion in Tf_MakeDirsRec when it was passed a malformed path.

Also adding the test cases that were failing without all these fixes.

Relates to #1441, #1378.

…rmed

directory paths on Windows ("/c:/foo/bar.usd"). Just add a simple check for
the infinite recursion rather than trying to figure out and avoid conditions
that might lead to it.
… raise

an exception if this function is passed a non-canonical Windows path.
A symlink can specify either an absolute or relative path. This change adds
a check for the "relative" flag, and converts the symlink path to a full path,
since that's what callers to this function assume will be returned.
Tests absolute paths without drive latters, relative paths, and some more
challenging symlink tests, including resolving symlinks while inside a
symlink directory.
@jilliene
Copy link

jilliene commented Mar 2, 2021

Filed as internal issue #USD-6591

@pixar-oss pixar-oss merged commit 9163050 into PixarAnimationStudios:dev Mar 19, 2021
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants