--- /dev/null
+diff -ur rpm-4.5.orig/lib/rpmds.c rpm-4.5/lib/rpmds.c
+--- rpm-4.5.orig/lib/rpmds.c 2019-06-01 18:55:39.433000000 +0200
++++ rpm-4.5/lib/rpmds.c 2019-08-16 10:50:36.274000000 +0200
+@@ -3008,6 +3008,8 @@
+ case SHT_DYNAMIC:
+ data = NULL;
+ while ((data = elf_getdata (scn, data)) != NULL) {
++ if (shdr->sh_entsize == 0)
++ continue;
+ /*@-boundswrite@*/
+ for (cnt = 0; cnt < (shdr->sh_size / shdr->sh_entsize); ++cnt) {
+ dyn = gelf_getdyn (data, cnt, &dyn_mem);
+diff -ur rpm-4.5.orig/rpmdb/legacy.c rpm-4.5/rpmdb/legacy.c
+--- rpm-4.5.orig/rpmdb/legacy.c 2007-07-30 04:28:13.000000000 +0200
++++ rpm-4.5/rpmdb/legacy.c 2019-08-16 10:35:01.076000000 +0200
+@@ -99,7 +99,7 @@
+ /*@-branchstate -uniondef @*/
+ while (!bingo && (scn = elf_nextscn(elf, scn)) != NULL) {
+ (void) gelf_getshdr(scn, &shdr);
+- if (shdr.sh_type != SHT_DYNAMIC)
++ if (shdr.sh_type != SHT_DYNAMIC || shdr.sh_entsize == 0)
+ continue;
+ while (!bingo && (data = elf_getdata (scn, data)) != NULL) {
+ int maxndx = data->d_size / shdr.sh_entsize;
Summary(uk.UTF-8): Менеджер пакетів від RPM
Name: rpm
Version: 4.5
-Release: 87
+Release: 88
License: LGPL
Group: Base
Source0: %{name}-%{version}.tar.gz
Patch116: %{name}-trigger-flags-int-type.patch
Patch117: %{name}-rpm2cpio-xz.patch
Patch118: %{name}-noarch-subpackages.patch
+Patch119: %{name}-div0.patch
URL: http://rpm5.org/
BuildRequires: autoconf >= 2.57
BuildRequires: automake >= 1.4
%patch116 -p1
%patch117 -p1
%patch118 -p1
+%patch119 -p1
mv -f po/{sr,sr@Latn}.po
rm -rf sqlite zlib popt