mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-08-28 13:21:19 +00:00
add more device options
This commit is contained in:
parent
f3539686bd
commit
314a51dff3
28 changed files with 162 additions and 82 deletions
|
|
@ -398,7 +398,7 @@ namespace MediaBrowser.Common.Implementations.HttpClientManager
|
|||
|
||||
options.CancellationToken.ThrowIfCancellationRequested();
|
||||
|
||||
return GetResponseInfo(httpResponse, httpResponse.GetResponseStream(), GetContentLength(httpResponse));
|
||||
return GetResponseInfo(httpResponse, httpResponse.GetResponseStream(), GetContentLength(httpResponse), httpResponse);
|
||||
}
|
||||
|
||||
using (var response = await httpWebRequest.GetResponseAsync().ConfigureAwait(false))
|
||||
|
|
@ -417,7 +417,7 @@ namespace MediaBrowser.Common.Implementations.HttpClientManager
|
|||
|
||||
memoryStream.Position = 0;
|
||||
|
||||
return GetResponseInfo(httpResponse, memoryStream, memoryStream.Length);
|
||||
return GetResponseInfo(httpResponse, memoryStream, memoryStream.Length, null);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -480,9 +480,9 @@ namespace MediaBrowser.Common.Implementations.HttpClientManager
|
|||
return exception;
|
||||
}
|
||||
|
||||
private HttpResponseInfo GetResponseInfo(HttpWebResponse httpResponse, Stream content, long? contentLength)
|
||||
private HttpResponseInfo GetResponseInfo(HttpWebResponse httpResponse, Stream content, long? contentLength, IDisposable disposable)
|
||||
{
|
||||
return new HttpResponseInfo
|
||||
return new HttpResponseInfo(disposable)
|
||||
{
|
||||
Content = content,
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue