mirror of
https://github.com/BepInEx/dotnet-runtime.git
synced 2026-11-27 13:19:31 -10:00
MultipartContent doesn't override CreateContentReadStreamAsync. This means that a ReadAsStreamAsync operation will end up serializing all of the content to a MemoryStream, which can be problematic for very large content, preventing such content from being uploaded with some HttpClientHandlers. This change overrides CreateContentReadStreamAsync to use a custom stream that delegates to all of the inner streams from each content. Commit migrated from https://github.com/dotnet/corefx/commit/b1d20b427fb68f468740b5ad55c04d41064e1396