]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
* dwarf2read.c (add_index_entry): Use VEC_last, not VEC_length.
authorTom Tromey <tromey@redhat.com>
Fri, 15 Apr 2011 15:05:04 +0000 (15:05 +0000)
committerTom Tromey <tromey@redhat.com>
Fri, 15 Apr 2011 15:05:04 +0000 (15:05 +0000)
gdb/ChangeLog
gdb/dwarf2read.c

index f9ffd3270fb4d5165acca745989c95f731383921..46e69cab1359cb51021ec5301f7286fc0e395555 100644 (file)
@@ -1,3 +1,7 @@
+2011-04-15  Tom Tromey  <tromey@redhat.com>
+
+       * dwarf2read.c (add_index_entry): Use VEC_last, not VEC_length.
+
 2011-04-15  Gary Benson  <gbenson@redhat.com>
 
        * MAINTAINERS: Add myself to write-after-approval section.
index 5bf98deb91604df4ec1fb726b7a6ebcadcbb7149..032fbd5f12dc3774f1b79e591cc9577f443a0ded 100644 (file)
@@ -15491,7 +15491,7 @@ add_index_entry (struct mapped_symtab *symtab, const char *name,
   /* Don't push an index twice.  Due to how we add entries we only
      have to check the last one.  */ 
   if (VEC_empty (offset_type, (*slot)->cu_indices)
-      || VEC_length (offset_type, (*slot)->cu_indices) != cu_index)
+      || VEC_last (offset_type, (*slot)->cu_indices) != cu_index)
     VEC_safe_push (offset_type, (*slot)->cu_indices, cu_index);
 }