aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--util/datamanager.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/util/datamanager.lua b/util/datamanager.lua
index 6d61aea5..ca77cda8 100644
--- a/util/datamanager.lua
+++ b/util/datamanager.lua
@@ -424,7 +424,8 @@ local function get_list_index(username, host, datastore)
end
if ih then
- return setmetatable({ file = ih }, index_mt);
+ local first_length = string.unpack(ih:read(index_item_size));
+ return setmetatable({ file = ih; { start = 0; length = first_length } }, index_mt);
end
local index, err = build_list_index(username, host, datastore);