diff options
author | Guilhem Moulin <guilhem@fripost.org> | 2019-01-20 20:16:53 +0100 |
---|---|---|
committer | Guilhem Moulin <guilhem@fripost.org> | 2019-01-20 21:59:36 +0100 |
commit | 8c0f59f3f3add18a9ee8be767f54f43996ddbd78 (patch) | |
tree | 3f8d6706d12bc66db4a8187994969d15f3474b05 /pullimap | |
parent | 452ae91f06bec4c21e7ba7b7bc4309b089f7afe3 (diff) |
Note on migrations.
Diffstat (limited to 'pullimap')
-rwxr-xr-x | pullimap | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -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.) }; |