Added patch with a hack that changes behaviour of headerGet() in rpm 4.6
compatibility mode in order to set the correct value of iteration index.
RPM 5 implementation of headerGet() sets it to 0 whereas rpmtdNext() expects
it to be -1 initially.
--- /dev/null
+--- rpm-5.4.15/lib/rpm46compat.h.rpmtdnext 2015-02-02 21:41:55.016116655 +0100
++++ rpm-5.4.15/lib/rpm46compat.h 2015-02-02 21:47:06.407763121 +0100
+@@ -223,6 +223,9 @@ static inline int headerGet_RPMorg(Heade
+ rflags &= ~HEADERGET_NOI18NSTRING;
+
+ rc = headerGet(h, (HE_t)he, rflags);
++
++ /* XXX: Hack. headerGet() sets he->ix to 0 whereas rpmtdNext expects it to be -1 initially */
++ he->ix = -1;
+
+ return rc;
+ }
Summary(uk.UTF-8): Менеджер пакетів від RPM
Name: rpm
Version: 5.4.15
-Release: 9
+Release: 10
License: LGPL v2.1
Group: Base
# http://rpm5.org/files/rpm/rpm-5.4/rpm-5.4.15-0.20140824.src.rpm
Patch85: rpm-CVE-2013-6435.patch
Patch86: rpm-CVE-2014-8118.patch
Patch87: %{name}-file-output-for-ELF.patch
+Patch88: %{name}-rpmtdnext.patch
# Patches imported from Mandriva
%patch85 -p1
%patch86 -p1
%patch87 -p1
+%patch88 -p1
%patch1000 -p1
%patch1001 -p1