فهرست منبع

Add HttpCompletionOption.ResponseHeadersRead to the buffering option to avoid potentially having 2 copies in memory

Claus Vium 5 سال پیش
والد
کامیت
dadfc09c01
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      Emby.Server.Implementations/HttpClientManager/HttpClientManager.cs

+ 1 - 1
Emby.Server.Implementations/HttpClientManager/HttpClientManager.cs

@@ -301,7 +301,7 @@ namespace Emby.Server.Implementations.HttpClientManager
                 };
             }
 
-            using (var response = await client.SendAsync(httpWebRequest, options.CancellationToken).ConfigureAwait(false))
+            using (var response = await client.SendAsync(httpWebRequest, HttpCompletionOption.ResponseHeadersRead, options.CancellationToken).ConfigureAwait(false))
             {
                 await EnsureSuccessStatusCode(response, options).ConfigureAwait(false);