diff options
Diffstat (limited to 'src/3rdparty/libbacktrace/libbacktrace/elf.c')
-rw-r--r-- | src/3rdparty/libbacktrace/libbacktrace/elf.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/3rdparty/libbacktrace/libbacktrace/elf.c b/src/3rdparty/libbacktrace/libbacktrace/elf.c index 79d56146..61014562 100644 --- a/src/3rdparty/libbacktrace/libbacktrace/elf.c +++ b/src/3rdparty/libbacktrace/libbacktrace/elf.c @@ -40,7 +40,12 @@ POSSIBILITY OF SUCH DAMAGE. */ #include <unistd.h> #ifdef HAVE_DL_ITERATE_PHDR -#include <link.h> + #ifdef HAVE_LINK_H + #include <link.h> + #endif + #ifdef HAVE_SYS_LINK_H + #include <sys/link.h> + #endif #endif #include "backtrace.h" @@ -1796,7 +1801,7 @@ elf_zlib_inflate (const unsigned char *pin, size_t sin, uint16_t *zdebug_table, /* An uncompressed block. */ /* If we've read ahead more than a byte, back up. */ - while (bits > 8) + while (bits >= 8) { --pin; bits -= 8; |