-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
TarEntry: link target path checks #78695
Comments
I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label. |
Tagging subscribers to this area: @dotnet/area-system-io-compression Issue Details@carlossanlop @jozkee do we need these checks: runtime/src/libraries/System.Formats.Tar/src/System/Formats/Tar/TarEntry.cs Lines 504 to 523 in ea4f2cc
I'm not sure what the For the hard link, it seems they check conditions on which creating the hard link will fail. So we might just as well fail when the link gets created. If we can get rid of the checks, we can simplify the code a little because there is no need to pass around I tried leaving them out, and there were no test failures.
|
@carlossanlop @jozkee do you recall why the first condition is there? |
ping @carlossanlop @jozkee |
@carlossanlop @jozkee do we need these checks:
runtime/src/libraries/System.Formats.Tar/src/System/Formats/Tar/TarEntry.cs
Lines 504 to 523 in ea4f2cc
I'm not sure what the
Path.Exists
is about?For the hard link, it seems they check conditions on which creating the hard link will fail. So we might just as well fail when the link gets created.
If we can get rid of the checks, we can simplify the code a little because there is no need to pass around
linkTargetPath
to this method.I tried leaving them out, and there were no test failures.
The text was updated successfully, but these errors were encountered: