aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--binutils/ChangeLog6
-rw-r--r--binutils/readelf.c6
2 files changed, 9 insertions, 3 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog
index 92d8602..53ac9fe 100644
--- a/binutils/ChangeLog
+++ b/binutils/ChangeLog
@@ -1,3 +1,9 @@
+2017-09-05 Nick Clifton <nickc@redhat.com>
+
+ PR 21995
+ * readelf.c (process_mips_specific): Add checks for a NULL data
+ pointer.
+
2017-09-05 Alexander Fedotov <alexander.fedotov@nxp.com>
Edmar Wienskoski <edmar.wienskoski@nxp.com
diff --git a/binutils/readelf.c b/binutils/readelf.c
index 571da2c..d61417a 100644
--- a/binutils/readelf.c
+++ b/binutils/readelf.c
@@ -15324,7 +15324,7 @@ process_mips_specific (FILE * file)
printf ("\n");
}
- if (ent < end)
+ if (data != NULL && ent < end)
{
printf (_(" Local entries:\n"));
printf (" %*s %10s %*s\n",
@@ -15854,7 +15854,7 @@ process_mips_specific (FILE * file)
}
printf ("\n");
- if (ent < local_end)
+ if (data != NULL && ent < local_end)
{
printf (_(" Local entries:\n"));
printf (" %*s %10s %*s\n",
@@ -15870,7 +15870,7 @@ process_mips_specific (FILE * file)
printf ("\n");
}
- if (gotsym < symtabno)
+ if (data != NULL && gotsym < symtabno)
{
int sym_width;