From: Jacek Caban <jacek@codeweavers.com> --- dlls/vcruntime140/Makefile.in | 3 +- dlls/vcruntime140/typeinfo_root.cpp | 45 +++++++++++++++++++++++++++++ 2 files changed, 47 insertions(+), 1 deletion(-) create mode 100644 dlls/vcruntime140/typeinfo_root.cpp diff --git a/dlls/vcruntime140/Makefile.in b/dlls/vcruntime140/Makefile.in index 715242c80ad..30231e1b074 100644 --- a/dlls/vcruntime140/Makefile.in +++ b/dlls/vcruntime140/Makefile.in @@ -3,4 +3,5 @@ IMPORTLIB = vcruntime140 SOURCES = \ misc.c \ - new.cpp + new.cpp \ + typeinfo_root.cpp diff --git a/dlls/vcruntime140/typeinfo_root.cpp b/dlls/vcruntime140/typeinfo_root.cpp new file mode 100644 index 00000000000..018c292ee3f --- /dev/null +++ b/dlls/vcruntime140/typeinfo_root.cpp @@ -0,0 +1,45 @@ +/* + * Copyright 2026 Jacek Caban for CodeWeavers + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#if 0 +#pragma makedep implib +#endif + +#ifdef _MSC_VER + +#include "windef.h" +#include "winnt.h" +#include "wine/asm.h" + +struct __type_info_node +{ + SLIST_HEADER list; +}; + +__type_info_node __type_info_root_node = {}; + +extern "C" void __cdecl __std_type_info_destroy_list(SLIST_HEADER*); + +extern "C" void __cdecl __wine_destroy_type_info_list(void) +{ + __std_type_info_destroy_list(&__type_info_root_node.list); +} + +__ASM_SECTION_POINTER( ".section .CRT$XTY", __wine_destroy_type_info_list ) + +#endif -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/10273