summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas "Pixel" Noble <pixel@nobis-crew.org>2009-12-17 23:59:12 +0100
committerNicolas "Pixel" Noble <pixel@nobis-crew.org>2009-12-17 23:59:12 +0100
commitb480ae1a7895fce092aafc334c57a4e86d9419ad (patch)
treec92c302706bbb9977e240e43730697b3b2662d10
parent8635cc606ba24f71383dead4ad9a34ba0275dc73 (diff)
Fixing a potential issue with Buffers.
-rw-r--r--lib/Buffer.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Buffer.cc b/lib/Buffer.cc
index eb97e4d..2d615b5 100644
--- a/lib/Buffer.cc
+++ b/lib/Buffer.cc
@@ -75,6 +75,8 @@ ssize_t Buffer::read(void *buf, size_t count) throw (GeneralException) {
return 0;
}
+ got_eof = false;
+
if (buf)
memcpy(buf, buffer + ptr, count);
ptr += count;
@@ -236,4 +238,5 @@ off_t Buffer::wtell() const {
void Buffer::reset() {
free(buffer);
realsiz = bufsiz = ptr = wptr = 0;
+ got_eof = false;
}