Bug 1395032 - Remove remainder of the VS CRT allocator mismatch hack. r=gps
authorMike Hommey <mh+mozilla@glandium.org>
Wed, 30 Aug 2017 14:06:13 +0900
changeset 378132 73f1010eea4c192e73a6878751f1ce698e706e4d
parent 378131 1a4aac2956cf01f4280b9179cb495ac66cdf84ea
child 378133 ec6c7dd9e25fd3e09dc1222e7bcee56647ce0395
push id94412
push userarchaeopteryx@coole-files.de
push dateFri, 01 Sep 2017 08:46:09 +0000
treeherdermozilla-inbound@d56571d7f1be [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgps
bugs1395032, 1186064
milestone57.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1395032 - Remove remainder of the VS CRT allocator mismatch hack. r=gps Bug 1186064 removed most of it when we started requiring VS 2015u2, but the "frex" function exported through mozglue.def.in was only used through the MSVCRT being patched by fixcrt.py, which is not done anymore. So the "frex" export is not used anymore, and so the "dumb_free_thunk" function is not used anymore as well.
memory/build/mozmemory_wrap.c
mozglue/build/mozglue.def.in
--- a/memory/build/mozmemory_wrap.c
+++ b/memory/build/mozmemory_wrap.c
@@ -136,27 +136,16 @@ asprintf_impl(char **str, const char *fm
 
    va_end(ap);
 
    return ret;
 }
 #endif
 
 #ifdef XP_WIN
-/*
- *  There's a fun allocator mismatch in (at least) the VS 2010 CRT
- *  (see the giant comment in $(topsrcdir)/mozglue/build/Makefile.in)
- *  that gets redirected here to avoid a crash on shutdown.
- */
-void
-dumb_free_thunk(void *ptr)
-{
-  return; /* shutdown leaks that we don't care about */
-}
-
 #include <wchar.h>
 
 /*
  *  We also need to provide our own impl of wcsdup so that we don't ask
  *  the CRT for memory from its heap (which will then be unfreeable).
  */
 wchar_t *
 wcsdup_impl(const wchar_t *src)
--- a/mozglue/build/mozglue.def.in
+++ b/mozglue/build/mozglue.def.in
@@ -30,11 +30,9 @@ EXPORTS
   strndup=wrap_strndup
   strdup=wrap_strdup
   _strdup=wrap_strdup
   wcsdup=wrap_wcsdup
   _wcsdup=wrap_wcsdup
   jemalloc_stats
   jemalloc_free_dirty_pages
   jemalloc_thread_local_arena
-  ; A hack to work around the CRT (see giant comment in Makefile.in)
-  frex=dumb_free_thunk
 #endif