X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Frepopage.h;h=739345ed6d74ed6b218c49d5b3812345daceac9e;hb=0e46e80434781d1acbc4f5716827bf8688450a30;hp=3ea834c95f769d424137d67ae135405b0e9879b2;hpb=9c90b39ddaf9aaac9740c9b6e719395050c8b04a;p=platform%2Fupstream%2Flibsolv.git diff --git a/src/repopage.h b/src/repopage.h index 3ea834c..739345e 100644 --- a/src/repopage.h +++ b/src/repopage.h @@ -13,11 +13,6 @@ typedef struct _Attrblobpage { - /* mapped_at == -1 --> not loaded, otherwise offset into - store->blob_store. The size of the mapping is REPOPAGE_BLOBSIZE - except for the last page. */ - unsigned int mapped_at; - /* page_size == 0 means the page is not backed by some file storage. Otherwise it is L*2+(compressed ? 1 : 0), with L being the data length. */ @@ -30,16 +25,26 @@ typedef struct _Repopagestore { long file_offset; /* pages in file start here */ unsigned char *blob_store; - Attrblobpage *pages; unsigned int num_pages; - /* mapped[i] is zero if nothing is mapped at logical page I, - otherwise it contains the pagenumber plus one (of the mapped page). */ + /* mapped_at[page] == -1 --> not loaded, otherwise offset into + store->blob_store. The size of the mapping is REPOPAGE_BLOBSIZE + except for the last page. */ + unsigned int *mapped_at; + + Attrblobpage *file_pages; + + /* mapped[i] is -1 if nothing is mapped at logical page I, + otherwise it contains the page number (of the mapped page). */ unsigned int *mapped; unsigned int nmapped; unsigned int rr_counter; } Repopagestore; +#ifdef __cplusplus +extern "C" { +#endif + void repopagestore_init(Repopagestore *store); void repopagestore_free(Repopagestore *store); @@ -54,4 +59,8 @@ int repopagestore_read_or_setup_pages(Repopagestore *store, FILE *fp, unsigned i void repopagestore_disable_paging(Repopagestore *store); +#ifdef __cplusplus +} +#endif + #endif /* LIBSOLV_REPOPAGE_H */