Skip to content

Commit 2d26ef0

Browse files
authored
[lldb-dap][test] Set disableASLR to False for tests (#113593)
When running in constrained environments like docker, disabling ASLR might fail with errors like: ``` AssertionError: False is not true : launch failed (Cannot launch '/__w/.../lldb-dap/stackTrace/subtleFrames/TestDAP_subtleFrames.test_subtleFrames/a.out': personality set failed: Operation not permitted) ``` E.g., #110303 Hence we already run `settings set target.disable-aslr false` as part of the init-commands for the non-DAP tests (see #88312 and https://discourse.llvm.org/t/running-lldb-in-a-container/76801). But we never adjusted it for the DAP tests. As a result we get conflicting test logs like: ``` { "arguments": { "commandEscapePrefix": null, "disableASLR": true, .... "initCommands": [ ... "settings set target.disable-aslr false", ``` Disabling ASLR by default in tests isn't useulf (it's only really a debugging aid for users). So this patch sets `disableASLR=False` by default.
1 parent c2d2b3b commit 2d26ef0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lldb/packages/Python/lldbsuite/test/tools/lldb-dap/lldbdap_testcase.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@ def launch(
367367
cwd=None,
368368
env=None,
369369
stopOnEntry=False,
370-
disableASLR=True,
370+
disableASLR=False,
371371
disableSTDIO=False,
372372
shellExpandArguments=False,
373373
trace=False,
@@ -451,7 +451,7 @@ def build_and_launch(
451451
cwd=None,
452452
env=None,
453453
stopOnEntry=False,
454-
disableASLR=True,
454+
disableASLR=False,
455455
disableSTDIO=False,
456456
shellExpandArguments=False,
457457
trace=False,

0 commit comments

Comments
 (0)