diff options
author | Nick Mathewson <nickm@torproject.org> | 2011-04-07 12:17:20 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2011-04-07 12:17:20 -0400 |
commit | 67d88a7d6021e95a2d423a9f26811accd1da39b6 (patch) | |
tree | 30d48f5f922b928f7727ed812905101e5bf24012 /src/or/buffers.c | |
parent | 07ab483e62457ee56187037304f25ec50cb0850a (diff) | |
parent | ba0cd8094f8e6ae0113ad69958d9d0973bb1f2c3 (diff) | |
download | tor-67d88a7d6021e95a2d423a9f26811accd1da39b6.tar.gz tor-67d88a7d6021e95a2d423a9f26811accd1da39b6.zip |
Merge remote-tracking branch 'origin/maint-0.2.2'
Conflicts:
src/common/address.c
src/common/compat_libevent.c
src/common/memarea.c
src/common/util.h
src/or/buffers.c
src/or/circuitbuild.c
src/or/circuituse.c
src/or/connection.c
src/or/directory.c
src/or/networkstatus.c
src/or/or.h
src/or/routerlist.c
Diffstat (limited to 'src/or/buffers.c')
-rw-r--r-- | src/or/buffers.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/or/buffers.c b/src/or/buffers.c index 2a5b4e15ce..70f8b4a52a 100644 --- a/src/or/buffers.c +++ b/src/or/buffers.c @@ -643,10 +643,14 @@ read_to_chunk_tls(buf_t *buf, chunk_t *chunk, tor_tls_t *tls, * (because of EOF), set *<b>reached_eof</b> to 1 and return 0. Return -1 on * error; else return the number of bytes read. */ +/* XXXX023 indicate "read blocked" somehow? */ int read_to_buf(int s, size_t at_most, buf_t *buf, int *reached_eof, int *socket_error) { + /* XXXX023 It's stupid to overload the return values for these functions: + * "error status" and "number of bytes read" are not mutually exclusive. + */ int r = 0; size_t total_read = 0; @@ -814,6 +818,9 @@ flush_chunk_tls(tor_tls_t *tls, buf_t *buf, chunk_t *chunk, int flush_buf(int s, buf_t *buf, size_t sz, size_t *buf_flushlen) { + /* XXXX023 It's stupid to overload the return values for these functions: + * "error status" and "number of bytes flushed" are not mutually exclusive. + */ int r; size_t flushed = 0; tor_assert(buf_flushlen); |