X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=db.h;h=df79904d94594753bf960538e0f006d82b614437;hb=b6d598e43038ad053e2b15141fcb3c18c13ba025;hp=d4baf530096f0f640628b86b03623f6d168dfa24;hpb=c41f998855416a8619751653f3cedd9bc6f0f4c0;p=plocate diff --git a/db.h b/db.h index d4baf53..df79904 100644 --- a/db.h +++ b/db.h @@ -4,13 +4,19 @@ #include struct Header { - char magic[8]; // "\0plocate"; - uint32_t version; // 0. + char magic[8]; // "\0plocate"; + uint32_t version; // 1. uint32_t hashtable_size; uint32_t extra_ht_slots; + uint32_t num_docids; uint64_t hash_table_offset_bytes; uint64_t filename_index_offset_bytes; -}; + + // Version 1 and up only. + uint32_t max_version; // Nominally 1, but can be increased if more features are added in a backward-compatible way. + uint32_t zstd_dictionary_length_bytes; + uint64_t zstd_dictionary_offset_bytes; +}; struct Trigram { uint32_t trgm;