summaryrefslogtreecommitdiff
path: root/git-compat-util.h
diff options
context:
space:
mode:
authorNicolas Pitre <nico@cam.org>2008-03-13 14:59:29 -0400
committerJunio C Hamano <gitster@pobox.com>2008-03-13 22:51:30 -0700
commitf746bae84e4746a861d9ebed29fd9255e5cd929f (patch)
tree04361153853f68efce7e726929426e55d91478ab /git-compat-util.h
parentb75aaa546e0593440d85c77d380c9b53e126ea02 (diff)
downloadgit-f746bae84e4746a861d9ebed29fd9255e5cd929f.tar.gz
pack-objects: proper pack time stamping with --max-pack-size
Runtime pack access is done in the pack file mtime order since recent packs are more likely to contain frequently used objects than old packs. However the --max-pack-size option can produce multiple packs with mtime in the reversed order as newer objects are always written first. Let's modify mtime of later pack files (when any) so they appear older than preceding ones when a repack creates multiple packs. Signed-off-by: Nicolas Pitre <nico@cam.org>
Diffstat (limited to 'git-compat-util.h')
-rw-r--r--git-compat-util.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/git-compat-util.h b/git-compat-util.h
index 73968e02b0..a18235e6d0 100644
--- a/git-compat-util.h
+++ b/git-compat-util.h
@@ -68,6 +68,7 @@
#include <sys/poll.h>
#include <sys/socket.h>
#include <sys/ioctl.h>
+#include <utime.h>
#ifndef NO_SYS_SELECT_H
#include <sys/select.h>
#endif