Skip to content

Commit f616642

Browse files
authored
fix tar strings (#74321)
1 parent a877553 commit f616642

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/libraries/System.Formats.Tar/src/System/Formats/Tar/TarEntry.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -465,7 +465,7 @@ private void VerifyPathsForEntryType(string filePath, string? linkTargetPath, bo
465465
// If the destination contains a directory segment, need to check that it exists
466466
if (!string.IsNullOrEmpty(directoryPath) && !Path.Exists(directoryPath))
467467
{
468-
throw new IOException(string.Format(SR.IO_PathNotFound_NoPathName, filePath));
468+
throw new IOException(string.Format(SR.IO_PathNotFound_Path, filePath));
469469
}
470470

471471
if (!Path.Exists(filePath))

src/libraries/System.Formats.Tar/src/System/Formats/Tar/TarFile.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ public static void ExtractToDirectory(string sourceFileName, string destinationD
217217

218218
if (!File.Exists(sourceFileName))
219219
{
220-
throw new FileNotFoundException(string.Format(SR.IO_FileNotFound, sourceFileName));
220+
throw new FileNotFoundException(string.Format(SR.IO_FileNotFound_FileName, sourceFileName));
221221
}
222222

223223
if (!Directory.Exists(destinationDirectoryName))
@@ -256,7 +256,7 @@ public static Task ExtractToDirectoryAsync(string sourceFileName, string destina
256256

257257
if (!File.Exists(sourceFileName))
258258
{
259-
return Task.FromException(new FileNotFoundException(string.Format(SR.IO_FileNotFound, sourceFileName)));
259+
return Task.FromException(new FileNotFoundException(string.Format(SR.IO_FileNotFound_FileName, sourceFileName)));
260260
}
261261

262262
if (!Directory.Exists(destinationDirectoryName))

0 commit comments

Comments
 (0)