]> git.pld-linux.org Git - packages/rpm.git/blobdiff - rpm-file-readelf-fix.patch
- no extra space at the end of x86_64 flags
[packages/rpm.git] / rpm-file-readelf-fix.patch
index 4c1f706eea0ad8564be53ae2449b85b00ab230b5..ef33518a69b76ad6ea4b0b14795cda9ed38b8f1f 100644 (file)
@@ -1,5 +1,5 @@
 --- rpm-4.3/file/src/readelf.c.orig    2004-03-19 21:12:58.000000000 +0100
-+++ rpm-4.3/file/src/readelf.c 2004-03-19 22:31:34.199417626 +0100
++++ rpm-4.3/file/src/readelf.c 2004-03-19 23:14:04.924440965 +0100
 @@ -136,6 +136,9 @@
                            getu32(fm, ph32.p_align) : 4) \
                         : (off_t) (ph64.p_align ?      \
                if (bufsize == -1) {
                        error(EXIT_FAILURE, 0, ": " "read failed (%s).\n", strerror(errno));
                        /*@notreached@*/
+@@ -290,7 +293,7 @@
+       noff = offset;
+       doff = ELF_ALIGN(offset + nh_namesz);
+-      if (offset + nh_namesz >= size) {
++      if (doff > size) {
+               /*
+                * We're past the end of the buffer.
+                */
+@@ -298,7 +301,7 @@
+       }
+       offset = ELF_ALIGN(doff + nh_descsz);
+-      if (offset + nh_descsz >= size)
++      if (offset > size)
+               return offset;
+       if (nh_namesz == 4 && strcmp((char *)&nbuf[noff], "GNU") == 0 &&
 @@ -601,7 +604,8 @@
                                error(EXIT_FAILURE, 0, "lseek failed (%s).\n", strerror(errno));
                                /*@notreached@*/
This page took 0.084265 seconds and 4 git commands to generate.