diff --git a/Core/Net/ResumingWebClient.cs b/Core/Net/ResumingWebClient.cs index c18a66307f..cba0feb490 100644 --- a/Core/Net/ResumingWebClient.cs +++ b/Core/Net/ResumingWebClient.cs @@ -124,15 +124,12 @@ protected override void OnOpenReadCompleted(OpenReadCompletedEventArgs e) log.DebugFormat("OnOpenReadCompleted got open stream, appending to {0}", destination); using (var fileStream = new FileStream(destination, FileMode.Append, FileAccess.Write)) { - try + // file:// URLs don't support timeouts + if (netStream.CanTimeout) { log.DebugFormat("Default stream read timeout is {0}", netStream.ReadTimeout); netStream.ReadTimeout = timeoutMs; } - catch - { - // file:// URLs don't support timeouts - } cancelTokenSrc = new CancellationTokenSource(); netStream.CopyTo(fileStream, new Progress(bytesDownloaded => {