| ... | ... | @@ -6092,17 +6092,13 @@ pub const SendError = error{ |
| 6092 | 6092 | pub const SendMsgError = SendError || error{ |
| 6093 | 6093 | /// The passed address didn't have the correct address family in its sa_family field. |
| 6094 | 6094 | AddressFamilyNotSupported, |
| 6095 | | |
| 6096 | 6095 | /// Returned when socket is AF.UNIX and the given path has a symlink loop. |
| 6097 | 6096 | SymLinkLoop, |
| 6098 | | |
| 6099 | 6097 | /// Returned when socket is AF.UNIX and the given path length exceeds `max_path_bytes` bytes. |
| 6100 | 6098 | NameTooLong, |
| 6101 | | |
| 6102 | 6099 | /// Returned when socket is AF.UNIX and the given path does not point to an existing file. |
| 6103 | 6100 | FileNotFound, |
| 6104 | 6101 | NotDir, |
| 6105 | | |
| 6106 | 6102 | /// The socket is not connected (connection-oriented sockets only). |
| 6107 | 6103 | SocketNotConnected, |
| 6108 | 6104 | AddressNotAvailable, |
| ... | ... | @@ -6400,14 +6396,7 @@ pub fn sendfile( |
| 6400 | 6396 | .SUCCESS => { |
| 6401 | 6397 | const amt: usize = @bitCast(rc); |
| 6402 | 6398 | total_written += amt; |
| 6403 | | if (in_len == 0 and amt == 0) { |
| 6404 | | // We have detected EOF from `in_fd`. |
| 6405 | | break; |
| 6406 | | } else if (amt < in_len) { |
| 6407 | | return total_written; |
| 6408 | | } else { |
| 6409 | | break; |
| 6410 | | } |
| 6399 | return total_written; |
| 6411 | 6400 | }, |
| 6412 | 6401 | |
| 6413 | 6402 | .BADF => unreachable, // Always a race condition. |