aboutsummaryrefslogtreecommitdiff
path: root/gdb/symfile.c
diff options
context:
space:
mode:
authorPierre Muller <muller@sourceware.org>2002-04-25 16:29:27 +0000
committerPierre Muller <muller@sourceware.org>2002-04-25 16:29:27 +0000
commit25bf3106359b27b442533f51e3ab3c2f9e62f1a1 (patch)
tree103740b24db29edee828027462f828265d5f8dd1 /gdb/symfile.c
parent24467a8686c09546ee59303b30ca12589b6b9bd6 (diff)
downloadgdb-25bf3106359b27b442533f51e3ab3c2f9e62f1a1.zip
gdb-25bf3106359b27b442533f51e3ab3c2f9e62f1a1.tar.gz
gdb-25bf3106359b27b442533f51e3ab3c2f9e62f1a1.tar.bz2
2002-04-25 Pierre Muller <muller@ics.u-strasbg.fr>
Fix PR gdb/508. * symfile.c (add_filename_language): Fix wrong xrealloc size argument.
Diffstat (limited to 'gdb/symfile.c')
-rw-r--r--gdb/symfile.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gdb/symfile.c b/gdb/symfile.c
index 2671770..7c7141d 100644
--- a/gdb/symfile.c
+++ b/gdb/symfile.c
@@ -1831,8 +1831,9 @@ add_filename_language (char *ext, enum language lang)
if (fl_table_next >= fl_table_size)
{
fl_table_size += 10;
- filename_language_table = xrealloc (filename_language_table,
- fl_table_size);
+ filename_language_table =
+ xrealloc (filename_language_table,
+ fl_table_size * sizeof (*filename_language_table));
}
filename_language_table[fl_table_next].ext = xstrdup (ext);