From 8c0f59f3f3add18a9ee8be767f54f43996ddbd78 Mon Sep 17 00:00:00 2001 From: Guilhem Moulin Date: Sun, 20 Jan 2019 20:16:53 +0100 Subject: Note on migrations. --- pullimap | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'pullimap') diff --git a/pullimap b/pullimap index e044df5..bd9b1cf 100755 --- a/pullimap +++ b/pullimap @@ -88,6 +88,11 @@ do { fcntl($STATE, F_SETLK, $struct_flock) or die "Can't lock $statefile: $!"; my $flags = fcntl($STATE, F_GETFD, 0) or die "fcntl F_GETFD: $!"; fcntl($STATE, F_SETFD, $flags | FD_CLOEXEC) or die "fcntl F_SETFD: $!"; + + # We have no version number in the statefile, but if we ever need a + # migration, we'll add a 1-byte header for the version number, and + # assume version 1.0 if the size of the file is a multiple of 4 + # bytes. (We can also use the fact that bytes 5 to 8 are never all 0.) }; -- cgit v1.2.3