summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2005-06-08 21:55:02 +0000
committerNick Mathewson <nickm@torproject.org>2005-06-08 21:55:02 +0000
commit87caad5445d14b5097529b2fbb5c24d0784df6ed (patch)
tree5489a1779d978b17b731987f795c131262b675b5 /src
parentbab2643b78d51ff1ea0a4a008b64a17af7ae64c0 (diff)
downloadtor-87caad5445d14b5097529b2fbb5c24d0784df6ed.tar.gz
tor-87caad5445d14b5097529b2fbb5c24d0784df6ed.zip
Fix an underflow in buffer use conting.
svn:r4360
Diffstat (limited to 'src')
-rw-r--r--src/or/buffers.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/or/buffers.c b/src/or/buffers.c
index 98dafb76b6..5a0ce6f47d 100644
--- a/src/or/buffers.c
+++ b/src/or/buffers.c
@@ -669,6 +669,7 @@ write_to_buf(const char *string, size_t string_len, buf_t *buf)
tor_assert(_buf_end(buf) == buf->mem);
memcpy(buf->mem, string+string_len, len2);
buf->datalen += len2;
+ buf_total_used += len2;
}
if (buf->datalen > buf->highwater)
buf->highwater = buf->datalen;