]> arthur.barton.de Git - bup.git/commit - lib/bup/index.py
Fix a bug where marginally old files couldn't be stored in the index
authorTim Hatch <tim@timhatch.com>
Sat, 16 Apr 2011 00:18:51 +0000 (17:18 -0700)
committerTim Hatch <tim@timhatch.com>
Sat, 16 Apr 2011 00:21:27 +0000 (17:21 -0700)
commit0820461c5dd5c63db3518862fea7f1c55f506543
tree3337248c085ba54bc01c98a4dc2a58ad4e492752
parentfcccac7e2d760267f592d88f475a69a14a43c701
Fix a bug where marginally old files couldn't be stored in the index

Due to the struct having unsigned timestamps, files with dates between Dec 13,
1901 and Jan 1, 1970 were not representable.  This change extends the struct to
be able to pack signed timestamps, which was the spirit of code in _fixup, and
extends the useful range back to 1901. Timestamps prior to 1901 are still
adjusted to zero, as they were before.

There should be no compatibility problems loading packed structures created
before this change, since positive values were truncated at 0x7fffffff.

Signed-off-by: Tim Hatch <tim@timhatch.com>
lib/bup/index.py
lib/bup/t/tindex.py