[binutils-gdb] Prevent a seg-fault in gprof when parsing a corrupt

Ulrich Weigand uweigand@de.ibm.com
Tue Aug 23 14:16:00 GMT 2016


Nick Clifton wrote:

> https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=4ca0333f073cb4d86fe9d4e64c9dfdca5deba1e0
> 
> commit 4ca0333f073cb4d86fe9d4e64c9dfdca5deba1e0
> Author: Nick Clifton <nickc@redhat.com>
> Date:   Mon Aug 22 14:16:26 2016 +0100
> 
>     Prevent a seg-fault in gprof when parsing a corrupt core file.
>     
>     	PR gprof/20499
>     	* corefile.c (core_create_syms_from): Avoid walking off the end of
>     	the symbol table.

This causes 

cc1: warnings being treated as errors
gprof/corefile.c: In function 'core_create_syms_from':
gprof/corefile.c:557: warning: comparison between signed and unsigned
make[4]: *** [corefile.o] Error 1

on my system (RHEL 5 using the GCC 4.1 system compiler).

Bye,
Ulrich

-- 
  Dr. Ulrich Weigand
  GNU/Linux compilers and toolchain
  Ulrich.Weigand@de.ibm.com



More information about the Binutils mailing list