From e501ac2e77ab4f145c75558aa456b7f5f481d254 Mon Sep 17 00:00:00 2001 From: Panu Matilainen Date: Mon, 24 Mar 2008 22:42:34 +0200 Subject: [PATCH] Remove bogus const from rpmRelocation struct --- lib/rpmcli.h | 2 +- lib/rpmfi.h | 4 ++-- lib/rpminstall.c | 2 +- lib/rpmte.c | 4 ++-- rpmqv.c | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/rpmcli.h b/lib/rpmcli.h index a9802f4..cd60d07 100644 --- a/lib/rpmcli.h +++ b/lib/rpmcli.h @@ -426,7 +426,7 @@ struct rpmInstallArguments_s { int noDeps; int incldocs; rpmRelocation * relocations; - const char * prefix; + char * prefix; const char * rootdir; }; diff --git a/lib/rpmfi.h b/lib/rpmfi.h index aba449f..6c6abea 100644 --- a/lib/rpmfi.h +++ b/lib/rpmfi.h @@ -91,8 +91,8 @@ typedef enum rpmFileAction_e { * We pass these around as an array with a sentinel. */ struct rpmRelocation_s { - const char * oldPath; /*!< NULL here evals to RPMTAG_DEFAULTPREFIX, */ - const char * newPath; /*!< NULL means to omit the file completely! */ + char * oldPath; /*!< NULL here evals to RPMTAG_DEFAULTPREFIX, */ + char * newPath; /*!< NULL means to omit the file completely! */ }; /** \ingroup rpmfi diff --git a/lib/rpminstall.c b/lib/rpminstall.c index d192b82..fb249fa 100644 --- a/lib/rpminstall.c +++ b/lib/rpminstall.c @@ -489,7 +489,7 @@ if (fileURL[0] == '=') { /* XXX reference held by transaction set */ eiu->h = headerFree(eiu->h); if (eiu->relocations) - eiu->relocations->oldPath = _constfree(eiu->relocations->oldPath); + eiu->relocations->oldPath = _free(eiu->relocations->oldPath); switch(rc) { case 0: diff --git a/lib/rpmte.c b/lib/rpmte.c index 94113ef..96468e5 100644 --- a/lib/rpmte.c +++ b/lib/rpmte.c @@ -36,8 +36,8 @@ static void delTE(rpmte p) if (p->relocs) { for (r = p->relocs; (r->oldPath || r->newPath); r++) { - r->oldPath = _constfree(r->oldPath); - r->newPath = _constfree(r->newPath); + r->oldPath = _free(r->oldPath); + r->newPath = _free(r->newPath); } p->relocs = _free(p->relocs); } diff --git a/rpmqv.c b/rpmqv.c index 6b24ecc..4e54aae 100644 --- a/rpmqv.c +++ b/rpmqv.c @@ -859,7 +859,7 @@ exit: #ifdef IAM_RPMEIU if (ia->relocations != NULL) for (i = 0; i < ia->numRelocations; i++) - ia->relocations[i].oldPath = _constfree(ia->relocations[i].oldPath); + ia->relocations[i].oldPath = _free(ia->relocations[i].oldPath); ia->relocations = _free(ia->relocations); #endif -- 2.7.4