Correct incorrect free in PE linker
authorTamar Christina <tamar@zhox.com>
Sat, 19 Aug 2017 07:31:34 +0000 (08:31 +0100)
committerTamar Christina <tamar@zhox.com>
Sat, 19 Aug 2017 07:31:34 +0000 (08:31 +0100)
commitee2e9ece388e75ac433097ac726a555a07ae0830
tree512d3860f3f75a5e284785d6cffb49759bc7b3f9
parent8e5b6ec6566da57d15b0810a07902d9eac85cb79
Correct incorrect free in PE linker

Summary:
The big-obj support (D3523) had introduced an early free on
the info structure. Because the pointer is not NULL'd
and the default of all the utility functions was to the
standard object format, it all kept working.

The one big-obj test that exists was subjected to a timing issue.
usually the test ran quickly enough that the allocator hasn't
had time to reclaim the memory yet, so it still passed.

This corrects it. Also as it so happens, static LLVM libraries
from mingw-w64 are compiled using big-obj.

Test Plan: ./validate

Reviewers: austin, bgamari, erikd, simonmar

Reviewed By: bgamari

Subscribers: rwbarton, thomie

GHC Trac Issues: #13815, #13093

Differential Revision: https://phabricator.haskell.org/D3862
rts/linker/PEi386.c