asan: readelf: process_mips_specific buffer overflow
[deliverable/binutils-gdb.git] / binutils / dwarf.c
index 7b5f7af8a1e2f0bd19a4a32f3fe954e45221c873..c2e73f72fe8495c395d68f666e0d8d3a8907b247 100644 (file)
@@ -3267,6 +3267,7 @@ process_debug_info (struct dwarf_section *           section,
 
       if ((do_loc || do_debug_loc || do_debug_ranges)
          && num_debug_info_entries == 0
+         && alloc_num_debug_info_entries > unit
          && ! do_types)
        {
          debug_information [unit].cu_offset = cu_offset;
@@ -7409,7 +7410,8 @@ regname_internal_riscv (unsigned int regno)
         document.  */
       switch (regno)
        {
-#define DECLARE_CSR(NAME,VALUE,CLASS) case VALUE + 4096: name = #NAME; break;
+#define DECLARE_CSR(NAME,VALUE,CLASS,DEFINE_VER,ABORT_VER) \
+  case VALUE + 4096: name = #NAME; break;
 #include "opcode/riscv-opc.h"
 #undef DECLARE_CSR
 
This page took 0.025326 seconds and 4 git commands to generate.