Skip to content

Commit 5c314d9

Browse files
committed
fix(tar): use sync codepath on sync methods
1 parent 75d1cf8 commit 5c314d9

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/ICSharpCode.SharpZipLib/Tar/TarInputStream.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@ public void Reset()
531531
/// <returns>
532532
/// The next TarEntry in the archive, or null.
533533
/// </returns>
534-
public TarEntry GetNextEntry() => GetNextEntryAsync(CancellationToken.None, true).GetAwaiter().GetResult();
534+
public TarEntry GetNextEntry() => GetNextEntryAsync(CancellationToken.None, false).GetAwaiter().GetResult();
535535

536536
private async ValueTask<TarEntry> GetNextEntryAsync(CancellationToken ct, bool isAsync)
537537
{

src/ICSharpCode.SharpZipLib/Tar/TarOutputStream.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ private async Task PutNextEntryAsync(TarEntry entry, CancellationToken cancellat
381381
/// to the output stream before this entry is closed and the
382382
/// next entry written.
383383
/// </summary>
384-
public void CloseEntry() => CloseEntryAsync(CancellationToken.None, true).GetAwaiter().GetResult();
384+
public void CloseEntry() => CloseEntryAsync(CancellationToken.None, false).GetAwaiter().GetResult();
385385

386386
private async Task CloseEntryAsync(CancellationToken cancellationToken, bool isAsync)
387387
{

0 commit comments

Comments
 (0)