问题
I am downloading a file from a remote server. The file is more than 2GB in size. I am requesting the file by calling
await _client.SendAsync(message, HttpCompletionOption.ResponseHeadersRead);
However, the call is throwing the above exception.
How can I download a file > 2GB?
回答1:
Your problem is very similar with following page.
HttpClient buffer size limit exceeded
Hope this will work for you.
来源:https://stackoverflow.com/questions/59513142/system-net-http-httprequestexception-cannot-write-more-bytes-to-the-buffer-than