aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorC. McEnroe <june@causal.agency>2020-02-18 17:37:19 -0500
committerC. McEnroe <june@causal.agency>2020-02-18 17:37:19 -0500
commitb8786e458787967e3b91afe0d0054c6858fc1f57 (patch)
tree831350d18bf8c5df45dd7119cb561fe865904d7a
parentImplement source address selection (diff)
downloadpounce-b8786e458787967e3b91afe0d0054c6858fc1f57.tar.gz
pounce-b8786e458787967e3b91afe0d0054c6858fc1f57.zip
Remove bad assert
If there's no room left in the buffer, tls_read will return 0 (since we gave it zero length to read into) and cause client->error to be set.
-rw-r--r--client.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/client.c b/client.c
index fe5eceb..b3fc32e 100644
--- a/client.c
+++ b/client.c
@@ -277,7 +277,6 @@ static bool intercept(const char *line, size_t len) {
}
void clientRecv(struct Client *client) {
- assert(client->len < sizeof(client->buf));
ssize_t read = tls_read(
client->tls,
&client->buf[client->len], sizeof(client->buf) - client->len