diff options
| author | marximimus <40419155+marximimus@users.noreply.github.com> | 2025-09-10 17:54:56 +0200 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2025-10-09 12:34:34 -0700 |
| commit | 07b6dbf8cae53d1e7a0c43cf514bb9286c3fd09e (patch) | |
| tree | 4a9c5df43fcda6b8419d54c4a3269512025131db /lib/std | |
| parent | df712d08332ad04a514f7c6f99a71b4be8bf531c (diff) | |
| download | zig-07b6dbf8cae53d1e7a0c43cf514bb9286c3fd09e.tar.gz zig-07b6dbf8cae53d1e7a0c43cf514bb9286c3fd09e.zip | |
std.crypto.tls.Client: fix infinite loop in std.Io.Writer.writeAll
Diffstat (limited to 'lib/std')
| -rw-r--r-- | lib/std/crypto/tls/Client.zig | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/lib/std/crypto/tls/Client.zig b/lib/std/crypto/tls/Client.zig index 8cfa942399..b697d624fa 100644 --- a/lib/std/crypto/tls/Client.zig +++ b/lib/std/crypto/tls/Client.zig @@ -942,7 +942,6 @@ fn drain(w: *Writer, data: []const []const u8, splat: usize) Writer.Error!usize if (prepared.cleartext_len < buf.len) break :done; } for (data[0 .. data.len - 1]) |buf| { - if (buf.len < min_buffer_len) break :done; const prepared = prepareCiphertextRecord(c, ciphertext_buf[ciphertext_end..], buf, .application_data); total_clear += prepared.cleartext_len; ciphertext_end += prepared.ciphertext_end; @@ -950,7 +949,6 @@ fn drain(w: *Writer, data: []const []const u8, splat: usize) Writer.Error!usize } const buf = data[data.len - 1]; for (0..splat) |_| { - if (buf.len < min_buffer_len) break :done; const prepared = prepareCiphertextRecord(c, ciphertext_buf[ciphertext_end..], buf, .application_data); total_clear += prepared.cleartext_len; ciphertext_end += prepared.ciphertext_end; |
