Fix ourdvsss's request timeout handling

This commit is contained in:
Misty 2020-06-21 19:39:54 +08:00
parent 3f59cd8178
commit 8445ec1b1c

View File

@ -310,7 +310,8 @@ namespace BililiveRecorder.Core
}; };
_stream = await _response.Content.ReadAsStreamAsync(); _stream = await _response.Content.ReadAsStreamAsync();
_stream.ReadTimeout = 3 * 1000; if (_response.Headers.ConnectionClose != true)
_stream.ReadTimeout = 3 * 1000;
StreamDownloadTask = Task.Run(_ReadStreamLoop); StreamDownloadTask = Task.Run(_ReadStreamLoop);
TriggerPropertyChanged(nameof(IsRecording)); TriggerPropertyChanged(nameof(IsRecording));