Within our Unix code, we are casting FileStream.Length to an int here:
| publicstaticSocketErrorSendFileAsync(SafeSocketHandlehandle,FileStreamfileStream,Action<long,SocketError>callback)=> |
| SendFileAsync(handle,fileStream,0,(int)fileStream.Length,callback); |
This would fail for any files greater than 2GiB in length.
Within our Unix code, we are casting
FileStream.Lengthto aninthere:runtime/src/libraries/System.Net.Sockets/src/System/Net/Sockets/SocketPal.Unix.cs
Lines 1811 to 1812 in 84c1f62
This would fail for any files greater than 2GiB in length.