From 91032b52b8fe9d3454a94ebb89c3af5500928d00 Mon Sep 17 00:00:00 2001 From: Rob Browning Date: Mon, 10 Oct 2016 15:53:19 -0500 Subject: [PATCH] Make INDEX_SIG a bit easier to understand Signed-off-by: Rob Browning --- lib/bup/index.py | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/lib/bup/index.py b/lib/bup/index.py index 9c81d9c..44e26ff 100644 --- a/lib/bup/index.py +++ b/lib/bup/index.py @@ -17,7 +17,21 @@ INDEX_HDR = 'BUPI\0\0\0\6' # Record times (mtime, ctime, atime) as xstat/metadata timespecs, and # store all of the times in the index so they won't interfere with the # forthcoming metadata cache. -INDEX_SIG = '!QQQqQqQqQQII20sHIIQ' +INDEX_SIG = ('!' + 'Q' # dev + 'Q' # ino + 'Q' # nlink + 'qQ' # ctime_s, ctime_ns + 'qQ' # mtime_s, mtime_ns + 'qQ' # atime_s, atime_ns + 'Q' # size + 'I' # mode + 'I' # gitmode + '20s' # sha + 'H' # flags + 'I' # children_ofs + 'I' # children_n + 'Q') # meta_ofs ENTLEN = struct.calcsize(INDEX_SIG) FOOTER_SIG = '!Q' -- 2.39.2