diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2019-02-07 17:07:18 -0500 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2019-02-07 17:07:18 -0500 |
| commit | 3e08b3a4f89ee8e6102fcc67fc7e77c5e3eba104 (patch) | |
| tree | e45ce5ccef05c44a202de42901bb3513ac0b178b /deps/lld/Common/ErrorHandler.cpp | |
| parent | 91baa574a5f7224b48e4499a9db0c5283d800ec3 (diff) | |
| download | zig-3e08b3a4f89ee8e6102fcc67fc7e77c5e3eba104.tar.gz zig-3e08b3a4f89ee8e6102fcc67fc7e77c5e3eba104.zip | |
update embedded LLD to 8.0.0rc2
Diffstat (limited to 'deps/lld/Common/ErrorHandler.cpp')
| -rw-r--r-- | deps/lld/Common/ErrorHandler.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/deps/lld/Common/ErrorHandler.cpp b/deps/lld/Common/ErrorHandler.cpp index d1cb3dbbe0..c059516daf 100644 --- a/deps/lld/Common/ErrorHandler.cpp +++ b/deps/lld/Common/ErrorHandler.cpp @@ -47,8 +47,9 @@ ErrorHandler &lld::errorHandler() { } void lld::exitLld(int Val) { - // Delete the output buffer so that any tempory file is deleted. - errorHandler().OutputBuffer.reset(); + // Delete any temporary file, while keeping the memory mapping open. + if (errorHandler().OutputBuffer) + errorHandler().OutputBuffer->discard(); // Dealloc/destroy ManagedStatic variables before calling // _exit(). In a non-LTO build, this is a nop. In an LTO |
