aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2009-09-14 12:29:50 +0000
committerNick Clifton <nickc@redhat.com>2009-09-14 12:29:50 +0000
commitc244d0505edb5cd7a76b77b0c4d309914ae0dec6 (patch)
tree8c4cda4e9fa36aae239368592ef52a2bdb2dbca2
parentdf58f7b0bfe78a674c5d93f5325a14e743977033 (diff)
downloadgdb-c244d0505edb5cd7a76b77b0c4d309914ae0dec6.zip
gdb-c244d0505edb5cd7a76b77b0c4d309914ae0dec6.tar.gz
gdb-c244d0505edb5cd7a76b77b0c4d309914ae0dec6.tar.bz2
* readelf.c (process_version_sections, process_symbol_table):
Use symbolic constants.
-rw-r--r--binutils/ChangeLog5
-rw-r--r--binutils/readelf.c14
2 files changed, 12 insertions, 7 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog
index 7962c5e..4036163 100644
--- a/binutils/ChangeLog
+++ b/binutils/ChangeLog
@@ -1,3 +1,8 @@
+2009-09-11 Paul Pluzhnikov <ppluzhnikov@google.com>
+
+ * readelf.c (process_version_sections, process_symbol_table):
+ Use symbolic constants.
+
2009-09-11 Nick Clifton <nickc@redhat.com>
* po/binutils.pot: Updated by the Translation project.
diff --git a/binutils/readelf.c b/binutils/readelf.c
index afa7d2a..64630f5 100644
--- a/binutils/readelf.c
+++ b/binutils/readelf.c
@@ -6852,8 +6852,8 @@ process_version_sections (FILE * file)
break;
default:
- nn = printf ("%4x%c", data[cnt + j] & 0x7fff,
- data[cnt + j] & 0x8000 ? 'h' : ' ');
+ nn = printf ("%4x%c", data[cnt + j] & VERSYM_VERSION,
+ data[cnt + j] & VERSYM_HIDDEN ? 'h' : ' ');
check_def = 1;
check_need = 1;
@@ -6947,10 +6947,10 @@ process_version_sections (FILE * file)
offset += ivd.vd_next;
}
- while (ivd.vd_ndx != (data[cnt + j] & 0x7fff)
+ while (ivd.vd_ndx != (data[cnt + j] & VERSYM_VERSION)
&& ivd.vd_next != 0);
- if (ivd.vd_ndx == (data[cnt + j] & 0x7fff))
+ if (ivd.vd_ndx == (data[cnt + j] & VERSYM_VERSION))
{
Elf_External_Verdaux evda;
Elf_Internal_Verdaux ivda;
@@ -7564,7 +7564,7 @@ process_symbol_table (FILE * file)
check_def = (psym->st_shndx != SHN_UNDEF);
- if ((vers_data & 0x8000) || vers_data > 1)
+ if ((vers_data & VERSYM_HIDDEN) || vers_data > 1)
{
if (version_info[DT_VERSIONTAGIDX (DT_VERNEED)]
&& (is_nobits || ! check_def))
@@ -7656,7 +7656,7 @@ process_symbol_table (FILE * file)
offset += ivd.vd_next;
}
- while (ivd.vd_ndx != (vers_data & 0x7fff)
+ while (ivd.vd_ndx != (vers_data & VERSYM_VERSION)
&& ivd.vd_next != 0);
offset -= ivd.vd_next;
@@ -7668,7 +7668,7 @@ process_symbol_table (FILE * file)
ivda.vda_name = BYTE_GET (evda.vda_name);
if (psym->st_name != ivda.vda_name)
- printf ((vers_data & 0x8000)
+ printf ((vers_data & VERSYM_HIDDEN)
? "@%s" : "@@%s",
ivda.vda_name < strtab_size
? strtab + ivda.vda_name : "<corrupt>");