commit - 32cb896c4b8b33da534b0d766496814425c71c52
commit + e559c32898498c8fd40f79311eb511d030fb44a6
blob - 298e2ba798ab4dd2c8023f73a4aa5d2bd950b746
blob + d7cf180ed2d58a007aaf610c8d2445e337a2c687
--- lib/got_fileindex_lib.h
+++ lib/got_fileindex_lib.h
* Variable length, and NUL-padded to a multiple of 8 on disk.
*/
char *path;
+
+ /* More data could be here if F_EXTENDED is set; To be determined... */
};
/* "Stages" of a file afflicted by a 3-way merge conflict. */
#define GOT_INDEX_ENTRY_STAGE_OURS 2
#define GOT_INDEX_ENTRY_STAGE_THEIRS 3
+struct got_fileindex {
+ uint32_t nentries;
+ TAILQ_HEAD(, got_fileindex_entry) entries;
+};
+
/* On-disk file index header structure. */
struct got_fileindex_hdr {
- uint32_t signature; /* big-endian on disk */
- uint32_t version; /* big-endian on disk */
+ uint32_t signature; /* big-endian */
+ uint32_t version; /* big-endian */
#define GOT_FILE_INDEX_VERSION 1
- uint32_t nentries; /* big-endian on disk */
- TAILQ_HEAD(, got_fileindex_entry) entries;
+ uint32_t nentries; /* big-endian */
+ /* list of concatenated fileindex entries */
uint8_t sha1[SHA1_DIGEST_LENGTH]; /* checksum of above on-disk data */
};