aboutsummaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
Diffstat (limited to 'util')
-rw-r--r--util/dbuffer.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/util/dbuffer.lua b/util/dbuffer.lua
index 63dca750..9ec40eb9 100644
--- a/util/dbuffer.lua
+++ b/util/dbuffer.lua
@@ -142,7 +142,7 @@ function dbuffer_methods:collapse(bytes)
local front_chunk = self.items:peek();
- if #front_chunk - self.front_consumed >= bytes then
+ if not front_chunk or #front_chunk - self.front_consumed >= bytes then
return;
end