Merge branch 'zh/read-cache-copy-name-entry-fix'
[alt-git.git] / pack-mtimes.h
blobcc957b3e852716541f764a40641462cb39fe0407
1 #ifndef PACK_MTIMES_H
2 #define PACK_MTIMES_H
4 #include "git-compat-util.h"
6 #define MTIMES_SIGNATURE 0x4d544d45 /* "MTME" */
7 #define MTIMES_VERSION 1
9 struct packed_git;
12 * Loads the .mtimes file corresponding to "p", if any, returning zero
13 * on success.
15 int load_pack_mtimes(struct packed_git *p);
17 /* Returns the mtime associated with the object at position "pos" (in
18 * lexicographic/index order) in pack "p".
20 * Note that it is a BUG() to call this function if either (a) "p" does
21 * not have a corresponding .mtimes file, or (b) it does, but it hasn't
22 * been loaded
24 uint32_t nth_packed_mtime(struct packed_git *p, uint32_t pos);
26 #endif