diff options
author | Panu Matilainen <pmatilai@redhat.com> | 2007-12-04 11:25:46 +0200 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2007-12-04 11:25:46 +0200 |
commit | dbdbe8010cd944f026a5a4e5d071eb31d29d81c4 (patch) | |
tree | b7b0f4014409f8514a1729b48a8776660747d149 /lib/rpmds.c | |
parent | 422fa0dbeab879d3510c879554c33e359e0ab7ab (diff) | |
download | librpm-tizen-dbdbe8010cd944f026a5a4e5d071eb31d29d81c4.tar.gz librpm-tizen-dbdbe8010cd944f026a5a4e5d071eb31d29d81c4.tar.bz2 librpm-tizen-dbdbe8010cd944f026a5a4e5d071eb31d29d81c4.zip |
Eliminate debug junk from the API
- add some helper macros to accomplish the same, easy to enable / disable
as needed
Diffstat (limited to 'lib/rpmds.c')
-rw-r--r-- | lib/rpmds.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/rpmds.c b/lib/rpmds.c index 2b9062484..a0bae296c 100644 --- a/lib/rpmds.c +++ b/lib/rpmds.c @@ -44,22 +44,22 @@ struct rpmds_s { int nopromote; /*!< Don't promote Epoch: in rpmdsCompare()? */ int nrefs; /*!< Reference count. */ }; -rpmds XrpmdsUnlink(rpmds ds, const char * msg, const char * fn, unsigned ln) +rpmds rpmdsUnlink(rpmds ds, const char * msg) { if (ds == NULL) return NULL; if (_rpmds_debug && msg != NULL) -fprintf(stderr, "--> ds %p -- %d %s at %s:%u\n", ds, ds->nrefs, msg, fn, ln); +fprintf(stderr, "--> ds %p -- %d %s\n", ds, ds->nrefs, msg); ds->nrefs--; return NULL; } -rpmds XrpmdsLink(rpmds ds, const char * msg, const char * fn, unsigned ln) +rpmds rpmdsLink(rpmds ds, const char * msg) { if (ds == NULL) return NULL; ds->nrefs++; if (_rpmds_debug && msg != NULL) -fprintf(stderr, "--> ds %p ++ %d %s at %s:%u\n", ds, ds->nrefs, msg, fn, ln); +fprintf(stderr, "--> ds %p ++ %d %s\n", ds, ds->nrefs, msg); return ds; } @@ -192,7 +192,7 @@ fprintf(stderr, "*** ds %p\t%s[%d]\n", ds, ds->Type, ds->Count); exit: /* FIX: ds->Flags may be NULL */ - ds = rpmdsLink(ds, (ds ? ds->Type : NULL)); + ds = rpmdsLink(ds, (ds ? ds->Type : RPMDBG())); return ds; } @@ -311,7 +311,7 @@ rpmds rpmdsThis(Header h, rpmTag tagN, int32_t Flags) } exit: - return rpmdsLink(ds, (ds ? ds->Type : NULL)); + return rpmdsLink(ds, (ds ? ds->Type : RPMDBG())); } rpmds rpmdsSingle(rpmTag tagN, const char * N, const char * EVR, int32_t Flags) |