Skip to content

Commit

Permalink
Make sure MaximumResponseHeadersLength is not set when using WebReque…
Browse files Browse the repository at this point in the history
…stConnection on core
  • Loading branch information
Mpdreamz committed Sep 3, 2018
1 parent e6eb8dc commit 02f34ff
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Elasticsearch.Net/Connection/HttpWebRequestConnection.cs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,8 @@ protected virtual HttpWebRequest CreateWebRequest(RequestData requestData)

request.Accept = requestData.Accept;
request.ContentType = requestData.RequestMimeType;
#if !DOTNETCORE
#if FEATURE_HTTPWEBREQUEST
// on netstandard/netcoreapp2.0 this throws argument exception
request.MaximumResponseHeadersLength = -1;
#endif
request.Pipelined = requestData.Pipelined;
Expand Down

0 comments on commit 02f34ff

Please sign in to comment.