| author | |
| committer | |
| log | 990031444dde4da223adcadfd2f2824f5baa0812 |
| tree | 7f35b99c36839e9d5cefc96dc2c0ddb4610b9e48 |
| parent | 01973a8a1610b76f7acfd7d0105aecbf6e9316fd |
1 files changed, 2 insertions(+), 0 deletions(-)
lib/std/io/Reader.zig+2| ... | ... | @@ -131,8 +131,10 @@ pub const Limit = enum(usize) { |
| 131 | 131 | }; |
| 132 | 132 | |
| 133 | 133 | pub fn read(r: Reader, bw: *BufferedWriter, limit: Limit) RwError!usize { |
| 134 | const before = bw.count; | |
| 134 | 135 | const n = try r.vtable.read(r.context, bw, limit); |
| 135 | 136 | assert(n <= @intFromEnum(limit)); |
| 137 | assert(bw.count == before + n); | |
| 136 | 138 | return n; |
| 137 | 139 | } |
| 138 | 140 |