aboutsummaryrefslogtreecommitdiffstats
path: root/lib/bufferstore.cc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bufferstore.cc')
-rw-r--r--lib/bufferstore.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/bufferstore.cc b/lib/bufferstore.cc
index ea4bab6..f2686dc 100644
--- a/lib/bufferstore.cc
+++ b/lib/bufferstore.cc
@@ -179,3 +179,8 @@ void bufferStore::addDWord(long a) {
buff[len++] = (a>>16) & 0xff;
buff[len++] = (a>>24) & 0xff;
}
+
+void bufferStore::truncate(long newLen) {
+ if (newLen < len)
+ len = newLen;
+}