rpm/rpm-4.7.0-beta1-installangs.patch
Panu Matilainen e15b00592e - fix _install_langs behavior (#489235)
- fix recording of file states into rpmdb on install
2009-03-09 13:08:01 +00:00

23 lines
851 B
Diff

commit cdcbd324fe41cd729434576200593c0fbda44a19
Author: Panu Matilainen <pmatilai@redhat.com>
Date: Mon Mar 9 14:57:46 2009 +0200
Unbreak %_install_langs handling (rhbz#489235)
- using rpmfiFLangs() in skipFiles() broke the %_install_langs logic,
causing all files to be skipped if install langs, eek
diff --git a/lib/transaction.c b/lib/transaction.c
index 2940634..25a147a 100644
--- a/lib/transaction.c
+++ b/lib/transaction.c
@@ -488,7 +488,8 @@ static void skipFiles(const rpmts ts, rpmte p)
/*
* Skip i18n language specific files.
*/
- if (ts->installLangs != NULL && (flangs = rpmfiFLangs(fi)) != NULL) {
+ flangs = (ts->installLangs != NULL) ? rpmfiFLangs(fi) : NULL;
+ if (flangs != NULL && *flangs != '\0') {
const char *l, *le;
char **lang;
for (lang = ts->installLangs; *lang != NULL; lang++) {