diff --git a/dlls/msvcr100/msvcr100.spec b/dlls/msvcr100/msvcr100.spec index 6a9461bf57a..9c20f28d6d0 100644 --- a/dlls/msvcr100/msvcr100.spec +++ b/dlls/msvcr100/msvcr100.spec @@ -465,8 +465,8 @@ @ stub -arch=win64 ?lock@reader_writer_lock@Concurrency@@QEAAXXZ @ stub -arch=win32 ?lock_read@reader_writer_lock@Concurrency@@QAEXXZ @ stub -arch=win64 ?lock_read@reader_writer_lock@Concurrency@@QEAAXXZ -@ stub -arch=win32 ?name@type_info@@QBEPBDPAU__type_info_node@@@Z # public: char const * __thiscall type_info::name(struct __type_info_node *)const -@ stub -arch=win64 ?name@type_info@@QEBAPEBDPEAU__type_info_node@@@Z # public: char const * __ptr64 __cdecl type_info::name(struct __type_info_node * __ptr64)const __ptr64 +@ thiscall -arch=win32 ?name@type_info@@QBEPBDPAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ cdecl -arch=win64 ?name@type_info@@QEBAPEBDPEAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method @ stub -arch=win32 ?native_handle@critical_section@Concurrency@@QAEAAV12@XZ @ stub -arch=win64 ?native_handle@critical_section@Concurrency@@QEAAAEAV12@XZ @ cdecl -arch=arm ?raw_name@type_info@@QBAPBDXZ(ptr) MSVCRT_type_info_raw_name diff --git a/dlls/msvcr110/msvcr110.spec b/dlls/msvcr110/msvcr110.spec index 68b48b79690..0034b2f0af4 100644 --- a/dlls/msvcr110/msvcr110.spec +++ b/dlls/msvcr110/msvcr110.spec @@ -755,9 +755,9 @@ @ stub -arch=arm ?lock_read@reader_writer_lock@Concurrency@@QAAXXZ @ stub -arch=i386 ?lock_read@reader_writer_lock@Concurrency@@QAEXXZ @ stub -arch=win64 ?lock_read@reader_writer_lock@Concurrency@@QEAAXXZ -@ stub -arch=arm ?name@type_info@@QBAPBDPAU__type_info_node@@@Z -@ stub -arch=i386 ?name@type_info@@QBEPBDPAU__type_info_node@@@Z # public: char const * __thiscall type_info::name(struct __type_info_node *)const -@ stub -arch=win64 ?name@type_info@@QEBAPEBDPEAU__type_info_node@@@Z # public: char const * __ptr64 __cdecl type_info::name(struct __type_info_node * __ptr64)const __ptr64 +@ cdecl -arch=arm ?name@type_info@@QBAPBDPAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ thiscall -arch=i386 ?name@type_info@@QBEPBDPAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ cdecl -arch=win64 ?name@type_info@@QEBAPEBDPEAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method @ stub -arch=arm ?native_handle@critical_section@Concurrency@@QAAAAV12@XZ @ stub -arch=i386 ?native_handle@critical_section@Concurrency@@QAEAAV12@XZ @ stub -arch=win64 ?native_handle@critical_section@Concurrency@@QEAAAEAV12@XZ diff --git a/dlls/msvcr80/msvcr80.spec b/dlls/msvcr80/msvcr80.spec index 105970af0d6..1caa7e015e9 100644 --- a/dlls/msvcr80/msvcr80.spec +++ b/dlls/msvcr80/msvcr80.spec @@ -113,8 +113,8 @@ @ cdecl -arch=win64 ?_wsopen@@YAHPEB_WHHH@Z(wstr long long long) MSVCRT__wsopen @ thiscall -arch=i386 ?before@type_info@@QBEHABV1@@Z(ptr ptr) MSVCRT_type_info_before @ cdecl -arch=win64 ?before@type_info@@QEBAHAEBV1@@Z(ptr ptr) MSVCRT_type_info_before -@ stub -arch=win32 ?name@type_info@@QBEPBDPAU__type_info_node@@@Z # public: char const * __thiscall type_info::name(struct __type_info_node *)const -@ stub -arch=win64 ?name@type_info@@QEBAPEBDPEAU__type_info_node@@@Z # public: char const * __ptr64 __cdecl type_info::name(struct __type_info_node * __ptr64)const __ptr64 +@ thiscall -arch=win32 ?name@type_info@@QBEPBDPAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ cdecl -arch=win64 ?name@type_info@@QEBAPEBDPEAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method @ cdecl -arch=arm ?raw_name@type_info@@QBAPBDXZ(ptr) MSVCRT_type_info_raw_name @ thiscall -arch=i386 ?raw_name@type_info@@QBEPBDXZ(ptr) MSVCRT_type_info_raw_name @ cdecl -arch=win64 ?raw_name@type_info@@QEBAPEBDXZ(ptr) MSVCRT_type_info_raw_name diff --git a/dlls/msvcr90/msvcr90.spec b/dlls/msvcr90/msvcr90.spec index 20260e2c30e..b624bd0fbc9 100644 --- a/dlls/msvcr90/msvcr90.spec +++ b/dlls/msvcr90/msvcr90.spec @@ -113,8 +113,8 @@ @ cdecl -arch=win64 ?_wsopen@@YAHPEB_WHHH@Z(wstr long long long) MSVCRT__wsopen @ thiscall -arch=i386 ?before@type_info@@QBEHABV1@@Z(ptr ptr) MSVCRT_type_info_before @ cdecl -arch=win64 ?before@type_info@@QEBAHAEBV1@@Z(ptr ptr) MSVCRT_type_info_before -@ stub -arch=win32 ?name@type_info@@QBEPBDPAU__type_info_node@@@Z # public: char const * __thiscall type_info::name(struct __type_info_node *)const -@ stub -arch=win64 ?name@type_info@@QEBAPEBDPEAU__type_info_node@@@Z # public: char const * __ptr64 __cdecl type_info::name(struct __type_info_node * __ptr64)const __ptr64 +@ thiscall -arch=win32 ?name@type_info@@QBEPBDPAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method +@ cdecl -arch=win64 ?name@type_info@@QEBAPEBDPEAU__type_info_node@@@Z(ptr ptr) type_info_name_internal_method @ cdecl -arch=arm ?raw_name@type_info@@QBAPBDXZ(ptr) MSVCRT_type_info_raw_name @ thiscall -arch=i386 ?raw_name@type_info@@QBEPBDXZ(ptr) MSVCRT_type_info_raw_name @ cdecl -arch=win64 ?raw_name@type_info@@QEBAPEBDXZ(ptr) MSVCRT_type_info_raw_name diff --git a/dlls/msvcrt/cpp.c b/dlls/msvcrt/cpp.c index cffcdd76489..e392208cbb1 100644 --- a/dlls/msvcrt/cpp.c +++ b/dlls/msvcrt/cpp.c @@ -1191,32 +1191,7 @@ DEFINE_THISCALL_WRAPPER(type_info_name_internal_method,8) const char * __thiscall type_info_name_internal_method(type_info * _this, struct __type_info_node *node) { static int once; - if (node && !once++) FIXME("type_info_node parameter ignored\n"); - if (!_this->name) - { - /* Create and set the demangled name */ - /* Note: mangled name in type_info struct always starts with a '.', while - * it isn't valid for mangled name. - * Is this '.' really part of the mangled name, or has it some other meaning ? - */ - char* name = __unDName(0, _this->mangled + 1, 0, MSVCRT_malloc, MSVCRT_free, 0x2800); - if (name) - { - unsigned int len = strlen(name); - - /* It seems _unDName may leave blanks at the end of the demangled name */ - while (len && name[--len] == ' ') - name[len] = '\0'; - - if (InterlockedCompareExchangePointer((void**)&_this->name, name, NULL)) - { - /* Another thread set this member since we checked above - use it */ - MSVCRT_free(name); - } - } - } - TRACE("(%p) returning %s\n", _this, _this->name); - return _this->name; + return MSVCRT_type_info_name(_this); }