diff options
author | Nick Mathewson <nickm@torproject.org> | 2005-04-23 14:26:02 +0000 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2005-04-23 14:26:02 +0000 |
commit | 5827e2e216ad759f240a0c332848cadf65794742 (patch) | |
tree | 0290c3e0f18d499ad77d106f622a28e395241dc8 /src/or/buffers.c | |
parent | ad4eca60ec0839abdaff69a0a896436cbd5b30d6 (diff) | |
download | tor-5827e2e216ad759f240a0c332848cadf65794742.tar.gz tor-5827e2e216ad759f240a0c332848cadf65794742.zip |
Fix "JAP-client" hideous ASN1 bug, twice. (Fix1: check more thoroughly for TLS errors when handling certs. Fix2: stop assert(0)ing on uncaught TLS errors.)debian-version-0.1.0.3-rc-200504231430-1
svn:r4085
Diffstat (limited to 'src/or/buffers.c')
-rw-r--r-- | src/or/buffers.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/or/buffers.c b/src/or/buffers.c index fe6b8d739d..7edc2cdf34 100644 --- a/src/or/buffers.c +++ b/src/or/buffers.c @@ -224,7 +224,7 @@ int read_to_buf_tls(tor_tls *tls, size_t at_most, buf_t *buf) { (int)buf_datalen(buf), (int)tor_tls_get_pending_bytes(tls), (int)at_most); - assert_no_tls_errors(); + check_no_tls_errors(); r = tor_tls_read(tls, buf->mem+buf->datalen, at_most); if (r<0) return r; @@ -281,6 +281,7 @@ int flush_buf_tls(tor_tls *tls, buf_t *buf, size_t *buf_flushlen) /* we want to let tls write even if flushlen is zero, because it might * have a partial record pending */ + check_no_tls_errors(); r = tor_tls_write(tls, buf->mem, *buf_flushlen); if (r < 0) { return r; |