diff options
author | Josh Stone <jistone@redhat.com> | 2009-08-19 14:40:53 -0700 |
---|---|---|
committer | Josh Stone <jistone@redhat.com> | 2009-08-19 14:40:53 -0700 |
commit | 966940426dbd5c44d7f25b0f2bd6b28cf829c384 (patch) | |
tree | ed11d5086ffeca70fdb4523dbf4a53f3ed3565e1 /tapsets.cxx | |
parent | b57ba9b863f0bd99f70d9e4d64c5a11ec75f7317 (diff) | |
download | systemtap-steved-966940426dbd5c44d7f25b0f2bd6b28cf829c384.tar.gz systemtap-steved-966940426dbd5c44d7f25b0f2bd6b28cf829c384.tar.xz systemtap-steved-966940426dbd5c44d7f25b0f2bd6b28cf829c384.zip |
PR10538: Use {...} for naming anonymous types
* tapsets.cxx (dwarf_type_name): Handle NULL dwarf_diename.
Diffstat (limited to 'tapsets.cxx')
-rw-r--r-- | tapsets.cxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tapsets.cxx b/tapsets.cxx index 3d38a3ce..aee01835 100644 --- a/tapsets.cxx +++ b/tapsets.cxx @@ -5604,7 +5604,9 @@ dwarf_type_name(Dwarf_Die& type_die, string& c_type) } if (done) { - c_type.append(dwarf_diename(&type_die)); + // this follows gdb precedent that anonymous structs/unions + // are displayed as "struct {...}" and "union {...}". + c_type.append(dwarf_diename(&type_die) ?: "{...}"); return true; } |