From 29fa21eb61293e677a8de4bacd843ef57192b60b Mon Sep 17 00:00:00 2001 From: Augusto Noronha Date: Fri, 10 Feb 2023 17:32:48 -0800 Subject: [PATCH] [lldb] Fix passing None as an env variable in TestMultipleDebuggers --- lldb/test/API/api/multiple-debuggers/TestMultipleDebuggers.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lldb/test/API/api/multiple-debuggers/TestMultipleDebuggers.py b/lldb/test/API/api/multiple-debuggers/TestMultipleDebuggers.py index 07e668c..64ee1a6 100644 --- a/lldb/test/API/api/multiple-debuggers/TestMultipleDebuggers.py +++ b/lldb/test/API/api/multiple-debuggers/TestMultipleDebuggers.py @@ -15,9 +15,12 @@ class TestMultipleSimultaneousDebuggers(TestBase): @skipIfNoSBHeaders @skipIfWindows def test_multiple_debuggers(self): - env = {self.dylibPath: self.getLLDBLibraryEnvVal(), - # We need this in order to run under ASAN, in case only LLDB is ASANified. - 'ASAN_OPTIONS': os.getenv('ASAN_OPTIONS', None)} + env = {self.dylibPath: self.getLLDBLibraryEnvVal()} + + # We need this in order to run under ASAN, in case only LLDB is ASANified. + asan_options = os.getenv('ASAN_OPTIONS', None) + if (asan_options is not None): + env['ASAN_OPTIONS'] = asan_options self.driver_exe = self.getBuildArtifact("multi-process-driver") self.buildDriver('multi-process-driver.cpp', self.driver_exe) -- 2.7.4