diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-12-22 12:44:26 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-12-22 13:51:18 +0000 |
commit | 1f799a9495795292af6f170925543bcee3c8dbae (patch) | |
tree | 0f4a74a6f088d13bb56606f434d1698bb3953841 /vcl/workben/wmffuzzer.cxx | |
parent | 7485fc2a1484f31631f62f97e5c64c0ae74c6416 (diff) |
Resolves: ofz#312 ignore leaks from InitVCL
because we can't call DeInitVCL
so try this
Change-Id: I9dec85551b30a8607c7b34e020e0d374c14b7741
Diffstat (limited to 'vcl/workben/wmffuzzer.cxx')
-rw-r--r-- | vcl/workben/wmffuzzer.cxx | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/vcl/workben/wmffuzzer.cxx b/vcl/workben/wmffuzzer.cxx index f859acb61a43..97c90e13d7fa 100644 --- a/vcl/workben/wmffuzzer.cxx +++ b/vcl/workben/wmffuzzer.cxx @@ -58,8 +58,17 @@ namespace } } +extern "C" +{ + __attribute__((weak)) void __lsan_enable(); + __attribute__((weak)) void __lsan_disable(); +} + extern "C" int LLVMFuzzerInitialize(int *argc, char ***argv) { + if (__lsan_enable) + __lsan_enable(); + setenv("SAL_USE_VCLPLUGIN", "svp", 1); osl_setCommandArgs(*argc, *argv); @@ -76,6 +85,9 @@ extern "C" int LLVMFuzzerInitialize(int *argc, char ***argv) utl::ConfigManager::EnableAvoidConfig(); InitVCL(); + if (__lsan_disable) + __lsan_disable(); + return 0; } |