diff options
author | Panu Matilainen <pmatilai@redhat.com> | 2008-02-04 12:33:02 +0200 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2008-02-04 12:33:02 +0200 |
commit | 21ff694d9ccacd86c1e570fdc3af030e98d6da10 (patch) | |
tree | 9d6a40ba9f57cfa364f16f374bb5e2b0c52c2c39 | |
parent | df1467c357aa18b4bc6a43df4832460d302054a4 (diff) | |
download | librpm-tizen-21ff694d9ccacd86c1e570fdc3af030e98d6da10.tar.gz librpm-tizen-21ff694d9ccacd86c1e570fdc3af030e98d6da10.tar.bz2 librpm-tizen-21ff694d9ccacd86c1e570fdc3af030e98d6da10.zip |
Remove double documention for exported header functions
-rw-r--r-- | rpmdb/header.c | 209 |
1 files changed, 0 insertions, 209 deletions
diff --git a/rpmdb/header.c b/rpmdb/header.c index 91620fe9f..6f19c5c5a 100644 --- a/rpmdb/header.c +++ b/rpmdb/header.c @@ -106,11 +106,6 @@ static size_t headerMaxbytes = (32*1024*1024); */ #define hdrchkRange(_dl, _off) ((_off) < 0 || (_off) > (_dl)) -/** \ingroup header - * Reference a header instance. - * @param h header - * @return referenced header instance - */ Header headerLink(Header h) { if (h == NULL) return NULL; @@ -122,11 +117,6 @@ fprintf(stderr, "--> h %p ++ %d at %s:%u\n", h, h->nrefs, __FILE__, __LINE__); return h; } -/** \ingroup header - * Dereference a header instance. - * @param h header - * @return NULL always - */ Header headerUnlink(Header h) { if (h == NULL) return NULL; @@ -136,11 +126,6 @@ fprintf(stderr, "--> h %p -- %d at %s:%u\n", h, h->nrefs, __FILE__, __LINE__); return NULL; } -/** \ingroup header - * Dereference a header instance. - * @param h header - * @return NULL always - */ Header headerFree(Header h) { (void) headerUnlink(h); @@ -170,10 +155,6 @@ Header headerFree(Header h) return h; } -/** \ingroup header - * Create new (empty) header instance. - * @return header - */ Header headerNew(void) { Header h = xcalloc(1, sizeof(*h)); @@ -199,10 +180,6 @@ static int indexCmp(const void * avp, const void * bvp) return (ap->info.tag - bp->info.tag); } -/** \ingroup header - * Sort tags in header. - * @param h header - */ void headerSort(Header h) { if (!(h->flags & HEADERFLAG_SORTED)) { @@ -237,12 +214,6 @@ void headerUnsort(Header h) qsort(h->index, h->indexUsed, sizeof(*h->index), offsetCmp); } -/** \ingroup header - * Return size of on-disk header representation in bytes. - * @param h header - * @param magicp include size of 8 bytes for (magic, 0)? - * @return size of on-disk header - */ unsigned headerSizeof(Header h, enum hMagic magicp) { indexEntry entry; @@ -748,11 +719,6 @@ errxit: return (void *) ei; } -/** \ingroup header - * Convert header to on-disk representation. - * @param h header (with pointers) - * @return on-disk header blob (i.e. with offsets) - */ void * headerUnload(Header h) { size_t length; @@ -804,15 +770,6 @@ indexEntry findEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type) return NULL; } -/** \ingroup header - * Delete tag in header. - * Removes all entries of type tag from the header, returns 1 if none were - * found. - * - * @param h header - * @param tag tag - * @return 0 on success, 1 on failure (INCONSISTENT) - */ int headerRemoveEntry(Header h, rpm_tag_t tag) { indexEntry last = h->index + h->indexUsed; @@ -850,11 +807,6 @@ int headerRemoveEntry(Header h, rpm_tag_t tag) return 0; } -/** \ingroup header - * Convert header to in-memory representation. - * @param uh on-disk header blob (i.e. with offsets) - * @return header - */ Header headerLoad(void * uh) { int32_t * ei = (int32_t *) uh; @@ -996,13 +948,6 @@ errxit: return h; } -/** \ingroup header - * Convert header to on-disk representation, and then reload. - * This is used to insure that all header data is in one chunk. - * @param h header (with pointers) - * @param tag region tag - * @return on-disk header (with offsets) - */ Header headerReload(Header h, rpm_tag_t tag) { Header nh; @@ -1027,11 +972,6 @@ Header headerReload(Header h, rpm_tag_t tag) return nh; } -/** \ingroup header - * Make a copy and convert header to in-memory representation. - * @param uh on-disk header blob (i.e. with offsets) - * @return header - */ Header headerCopyLoad(const void * uh) { int32_t * ei = (int32_t *) uh; @@ -1120,13 +1060,6 @@ exit: return h; } -/** \ingroup header - * Write (with unload) header to file handle. - * @param fd file handle - * @param h header - * @param magicp prefix write with 8 bytes of (magic, 0)? - * @return 0 on success, 1 on error - */ int headerWrite(FD_t fd, Header h, enum hMagic magicp) { ssize_t nb; @@ -1155,12 +1088,6 @@ exit: return (nb == length ? 0 : 1); } -/** \ingroup header - * Check if tag is in header. - * @param h header - * @param tag tag - * @return 1 on success, 0 on failure - */ int headerIsEntry(Header h, rpm_tag_t tag) { /* FIX: h modified by sort. */ @@ -1447,13 +1374,6 @@ static int intGetEntry(Header h, rpm_tag_t tag, return ((rc == 1) ? 1 : 0); } -/** \ingroup header - * Free data allocated when retrieved from header. - * @param h header - * @param data address of data (or NULL) - * @param type type of data (or -1 to force free) - * @return NULL always - */ void * headerFreeTag(Header h, rpm_data_t data, rpm_tagtype_t type) { if (data) { @@ -1466,19 +1386,6 @@ void * headerFreeTag(Header h, rpm_data_t data, rpm_tagtype_t type) return NULL; } -/** \ingroup header - * Retrieve tag value. - * Will never return RPM_I18NSTRING_TYPE! RPM_STRING_TYPE elements with - * RPM_I18NSTRING_TYPE equivalent entries are translated (if HEADER_I18NTABLE - * entry is present). - * - * @param h header - * @param tag tag - * @retval type address of tag value data type (or NULL) - * @retval p address of pointer to tag value(s) (or NULL) - * @retval c address of number of values (or NULL) - * @return 1 on success, 0 on failure - */ int headerGetEntry(Header h, rpm_tag_t tag, rpm_tagtype_t * type, rpm_data_t * p, @@ -1487,18 +1394,6 @@ int headerGetEntry(Header h, rpm_tag_t tag, return intGetEntry(h, tag, type, p, c, 0); } -/** \ingroup header - * Retrieve tag value using header internal array. - * Get an entry using as little extra RAM as possible to return the tag value. - * This is only an issue for RPM_STRING_ARRAY_TYPE. - * - * @param h header - * @param tag tag - * @retval type address of tag value data type (or NULL) - * @retval p address of pointer to tag value(s) (or NULL) - * @retval c address of number of values (or NULL) - * @return 1 on success, 0 on failure - */ int headerGetEntryMinMemory(Header h, rpm_tag_t tag, rpm_tagtype_t * type, rpm_data_t * p, @@ -1582,20 +1477,6 @@ grabData(rpm_tagtype_t type, rpm_constdata_t p, rpm_count_t c, int * lengthPtr) return data; } -/** \ingroup header - * Add tag to header. - * Duplicate tags are okay, but only defined for iteration (with the - * exceptions noted below). While you are allowed to add i18n string - * arrays through this function, you probably don't mean to. See - * headerAddI18NString() instead. - * - * @param h header - * @param tag tag - * @param type tag value data type - * @param p pointer to tag value(s) - * @param c number of values - * @return 1 on success, 0 on failure - */ int headerAddEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, rpm_constdata_t p, rpm_count_t c) { @@ -1639,20 +1520,6 @@ int headerAddEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, return 1; } -/** \ingroup header - * Append element to tag array in header. - * Appends item p to entry w/ tag and type as passed. Won't work on - * RPM_STRING_TYPE. Any pointers into header memory returned from - * headerGetEntryMinMemory() for this entry are invalid after this - * call has been made! - * - * @param h header - * @param tag tag - * @param type tag value data type - * @param p pointer to tag value(s) - * @param c number of values - * @return 1 on success, 0 on failure - */ int headerAppendEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, rpm_constdata_t p, rpm_count_t c) { @@ -1690,16 +1557,6 @@ int headerAppendEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, return 1; } -/** \ingroup header - * Add or append element to tag array in header. - * @todo Arg "p" should have const. - * @param h header - * @param tag tag - * @param type tag value data type - * @param p pointer to tag value(s) - * @param c number of values - * @return 1 on success, 0 on failure - */ int headerAddOrAppendEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, rpm_constdata_t p, rpm_count_t c) { @@ -1708,26 +1565,6 @@ int headerAddOrAppendEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, : headerAddEntry(h, tag, type, p, c)); } -/** \ingroup header - * Add locale specific tag to header. - * A NULL lang is interpreted as the C locale. Here are the rules: - * \verbatim - * - If the tag isn't in the header, it's added with the passed string - * as new value. - * - If the tag occurs multiple times in entry, which tag is affected - * by the operation is undefined. - * - If the tag is in the header w/ this language, the entry is - * *replaced* (like headerModifyEntry()). - * \endverbatim - * This function is intended to just "do the right thing". If you need - * more fine grained control use headerAddEntry() and headerModifyEntry(). - * - * @param h header - * @param tag tag - * @param string tag value - * @param lang locale - * @return 1 on success, 0 on failure - */ int headerAddI18NString(Header h, rpm_tag_t tag, const char * string, const char * lang) { @@ -1851,16 +1688,6 @@ int headerAddI18NString(Header h, rpm_tag_t tag, const char * string, return 0; } -/** \ingroup header - * Modify tag in header. - * If there are multiple entries with this tag, the first one gets replaced. - * @param h header - * @param tag tag - * @param type tag value data type - * @param p pointer to tag value(s) - * @param c number of values - * @return 1 on success, 0 on failure - */ int headerModifyEntry(Header h, rpm_tag_t tag, rpm_tagtype_t type, rpm_constdata_t p, rpm_count_t c) { @@ -1963,11 +1790,6 @@ struct headerIterator_s { int next_index; /*!< Next tag index. */ }; -/** \ingroup header - * Destroy header tag iterator. - * @param hi header tag iterator - * @return NULL always - */ HeaderIterator headerFreeIterator(HeaderIterator hi) { if (hi != NULL) { @@ -1977,11 +1799,6 @@ HeaderIterator headerFreeIterator(HeaderIterator hi) return hi; } -/** \ingroup header - * Create header tag iterator. - * @param h header - * @return header tag iterator - */ HeaderIterator headerInitIterator(Header h) { HeaderIterator hi = xmalloc(sizeof(*hi)); @@ -1993,15 +1810,6 @@ HeaderIterator headerInitIterator(Header h) return hi; } -/** \ingroup header - * Return next tag from header. - * @param hi header tag iterator - * @retval *tag tag - * @retval *type tag value data type - * @retval *p pointer to tag value(s) - * @retval *c number of values - * @return 1 on success, 0 on failure - */ int headerNextIterator(HeaderIterator hi, rpm_tag_t * tag, rpm_tagtype_t * type, @@ -2998,17 +2806,6 @@ rpmecFree(const headerSprintfExtension exts, rpmec ec) return NULL; } -/** \ingroup header - * Return formatted output string from header tags. - * The returned string must be free()d. - * - * @param h header - * @param fmt format to use - * @param tbltags array of tag name/value pairs - * @param extensions chained table of formatting extensions. - * @retval *errmsg error message (if any) - * @return formatted output string (malloc'ed) - */ char * headerSprintf(Header h, const char * fmt, const struct headerTagTableEntry_s * tbltags, const struct headerSprintfExtension_s * extensions, @@ -3244,12 +3041,6 @@ const struct headerSprintfExtension_s headerDefaultFormats[] = { { HEADER_EXT_LAST, NULL, { NULL } } }; -/** \ingroup header - * Duplicate tag values from one header into another. - * @param headerFrom source header - * @param headerTo destination header - * @param tagstocopy array of tags that are copied - */ void headerCopyTags(Header headerFrom, Header headerTo, rpm_tag_t * tagstocopy) { rpm_tag_t * p; |