-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Tar timestamp conversion from/to string and DateTimeOffset (#71038)
* Change double to decimal in timestamp conversions to preserve precision * Re-enable disabled test * Adjust assert message * Reuse FileSystemInfo Last*TimeUtc fields, use implicit cast operator to store as DateTimeOffset. * Fix using wrong fieldname for ctime. * Using 'G' for decimal to string conversion. Adjust test to not require a dot. The DateTimeOffset comparison done afterwards should suffice. * Ensure timestamps are converted to long, not int. * Add Epochalypse and Past-octal-limit timestamp tests * TarHelpers methods can be private * Remove unreachable code for adding ctime and atime before writing Pax entry. Add tests to ensure we always add those entries to the dictionary on construction. * Fix typo in test when retrieving ctime. * Make sure CTime adds nanoseconds on Unix when retrieving info from disk. Co-authored-by: carlossanlop <carlossanlop@users.noreply.github.com>
- Loading branch information
1 parent
df3bd55
commit 70e9ca0
Showing
12 changed files
with
347 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.