We do check whether the values we store for the line fit our data
representation in add_new_line, but on 32bit systems we would fail
to notice line overflowing.
https://bugzilla.redhat.com/show_bug.cgi?id=
1170810#c32
Signed-off-by: Mark Wielaard <mjw@redhat.com>
+2015-05-06 Mark Wielaard <mjw@redhat.com>
+
+ * dwarf_getsrclines.c (read_srclines): Use an int64_t to store and
+ check the line number.
+
2015-05-05 Mark Wielaard <mjw@redhat.com>
* dwarf_getaranges.c (dwarf_getaranges): Check there is enough data
Dwarf_Word addr = 0;
unsigned int op_index = 0;
unsigned int file = 1;
- int line = 1;
+ /* We only store an int, but want to check for overflow (see SET below). */
+ int64_t line = 1;
unsigned int column = 0;
uint_fast8_t is_stmt = default_is_stmt;
bool basic_block = false;