diff options
author | Kai Tietz <kai.tietz@onevision.com> | 2013-03-21 14:05:29 +0000 |
---|---|---|
committer | Kai Tietz <kai.tietz@onevision.com> | 2013-03-21 14:05:29 +0000 |
commit | 31fd86f1cf4e96c59614385d8038ed521f31ee1e (patch) | |
tree | 74ba2022f00a09f6c866607a5d2672aadc895b7a /ld/pe-dll.c | |
parent | 088ca6c1e30939f069331a25dabd49d99f06fd8e (diff) | |
download | gdb-31fd86f1cf4e96c59614385d8038ed521f31ee1e.zip gdb-31fd86f1cf4e96c59614385d8038ed521f31ee1e.tar.gz gdb-31fd86f1cf4e96c59614385d8038ed521f31ee1e.tar.bz2 |
* pe-dll.c (process_def_file_and_drectve): Don't handle VC
generated C++-symbols as stdcall/fastcall.
Diffstat (limited to 'ld/pe-dll.c')
-rw-r--r-- | ld/pe-dll.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/ld/pe-dll.c b/ld/pe-dll.c index 76a1ce3..bd3195f 100644 --- a/ld/pe-dll.c +++ b/ld/pe-dll.c @@ -782,14 +782,17 @@ process_def_file_and_drectve (bfd *abfd ATTRIBUTE_UNUSED, struct bfd_link_info * { for (i = 0; i < NE; i++) { - if (strchr (pe_def_file->exports[i].name, '@')) + /* Check for fastcall/stdcall-decoration, but ignore + C++ mangled names. */ + if (pe_def_file->exports[i].name[0] != '?' + && strchr (pe_def_file->exports[i].name, '@')) { /* This will preserve internal_name, which may have been pointing to the same memory as name, or might not have. */ int lead_at = (*pe_def_file->exports[i].name == '@'); char *tmp = xstrdup (pe_def_file->exports[i].name + lead_at); - char *tmp_at = strchr (tmp, '@'); + char *tmp_at = strrchr (tmp, '@'); if (tmp_at) *tmp_at = 0; |