diff options
author | Panu Matilainen <pmatilai@redhat.com> | 2007-12-13 20:35:33 +0200 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2007-12-13 20:35:33 +0200 |
commit | 1e96ead46670088e6b867cc989eadbef092d5864 (patch) | |
tree | 6a884ee7056ff9d8ceb3161dd0b1b758c0a078a2 /lib/rpmds.c | |
parent | 7e56c6355bea552d89e8d5d0a317763a8cee4a4f (diff) | |
download | librpm-tizen-1e96ead46670088e6b867cc989eadbef092d5864.tar.gz librpm-tizen-1e96ead46670088e6b867cc989eadbef092d5864.tar.bz2 librpm-tizen-1e96ead46670088e6b867cc989eadbef092d5864.zip |
Use rpm_tagtype_t everywhere for rpm (header) tagtype type
- typedef'ed as uint32_t, doesn't matter much but negative types dont exist
- easy to grep, easy to change...
- define RPM_FORCEFREE_TYPE instead of -1 "magic" for forcing
headerFreeData (ugh), easier to grep for and change than "-1"
Diffstat (limited to 'lib/rpmds.c')
-rw-r--r-- | lib/rpmds.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/rpmds.c b/lib/rpmds.c index 2dce7d462..322c54045 100644 --- a/lib/rpmds.c +++ b/lib/rpmds.c @@ -36,7 +36,7 @@ struct rpmds_s { int32_t * Refs; /*!< No. of file refs. */ int32_t BT; /*!< Package build time tie breaker. */ rpm_tag_t tagN; /*!< Header tag. */ - rpmTagType Nt, EVRt, Ft; /*!< Tag data types. */ + rpm_tagtype_t Nt, EVRt, Ft; /*!< Tag data types. */ int32_t Count; /*!< No. of elements */ int i; /*!< Element index. */ unsigned l; /*!< Low element (bsearch). */ @@ -123,13 +123,13 @@ rpmds rpmdsNew(Header h, rpm_tag_t tagN, int flags) HGE_t hge = (scareMem ? (HGE_t) headerGetEntryMinMemory : (HGE_t) headerGetEntry); rpm_tag_t tagBT = RPMTAG_BUILDTIME; - rpmTagType BTt; + rpm_tagtype_t BTt; int32_t * BTp; rpm_tag_t tagEVR, tagF; rpmds ds = NULL; const char * Type; const char ** N; - rpmTagType Nt; + rpm_tagtype_t Nt; rpm_count_t Count; if (tagN == RPMTAG_PROVIDENAME) { @@ -298,9 +298,9 @@ rpmds rpmdsThis(Header h, rpm_tag_t tagN, int32_t Flags) ds->tagN = tagN; ds->Count = 1; ds->N = N; - ds->Nt = -1; /* XXX to insure that hfd will free */ + ds->Nt = RPM_FORCEFREE_TYPE; /* XXX to insure that hfd will free */ ds->EVR = EVR; - ds->EVRt = -1; /* XXX to insure that hfd will free */ + ds->EVRt = RPM_FORCEFREE_TYPE; /* XXX to insure that hfd will free */ ds->Flags = xmalloc(sizeof(*ds->Flags)); ds->Flags[0] = Flags; ds->i = 0; { char pre[2]; @@ -345,9 +345,9 @@ rpmds rpmdsSingle(rpm_tag_t tagN, const char * N, const char * EVR, int32_t Flag } ds->Count = 1; ds->N = xmalloc(sizeof(*ds->N)); ds->N[0] = N; - ds->Nt = -1; /* XXX to insure that hfd will free */ + ds->Nt = RPM_FORCEFREE_TYPE; /* XXX to insure that hfd will free */ ds->EVR = xmalloc(sizeof(*ds->EVR)); ds->EVR[0] = EVR; - ds->EVRt = -1; /* XXX to insure that hfd will free */ + ds->EVRt = RPM_FORCEFREE_TYPE; /* XXX to insure that hfd will free */ ds->Flags = xmalloc(sizeof(*ds->Flags)); ds->Flags[0] = Flags; ds->i = 0; { char t[2]; |