Lines Matching refs:CatalogItem
49 typedef struct CatalogItem { struct
54 } CatalogItem; typedef
56 static void catalog_hash_func(const CatalogItem *i, struct siphash *state) { in catalog_hash_func()
61 static int catalog_compare_func(const CatalogItem *a, const CatalogItem *b) { in catalog_compare_func()
74 DEFINE_HASH_OPS(catalog_hash_ops, CatalogItem, catalog_hash_func, catalog_compare_func);
147 _cleanup_free_ CatalogItem *i = NULL; in finish_item()
154 i = new0(CatalogItem, 1); in finish_item()
375 CatalogItem *items, in write_catalog()
396 .catalog_item_size = htole64(sizeof(CatalogItem)), in write_catalog()
408 k = fwrite(items, 1, n * sizeof(CatalogItem), w); in write_catalog()
409 if (k != n * sizeof(CatalogItem)) { in write_catalog()
444 _cleanup_free_ CatalogItem *items = NULL; in catalog_update()
447 CatalogItem *i; in catalog_update()
474 items = new(CatalogItem, ordered_hashmap_size(h)); in catalog_update()
533 le64toh(h->catalog_item_size) < sizeof(CatalogItem) || in open_mmap()
549 CatalogItem *f = NULL, key = { .id = id }; in find_id()
675 const CatalogItem *items; in catalog_list()
686 items = (const CatalogItem*) ((const uint8_t*) p + le64toh(h->header_size)); in catalog_list()