Issue 142127
Summary [lldb-dap] inferior always inherits parent environment
Labels new issue
Assignees
Reporter nd
    Happens in lldb-dap version 21.0.0git (revision 7c996012ceee0997838e3246cce169652b0b6eb6).

To reproduce, debug the program by sending `launch { ... "env": {"FOO": "BAR"}}`

```
#include <cstdio>
#include <unistd.h>

int main() {
    char *s = *environ;
 for (int i = 0; s; i++) {
        printf("%s\n", s);
        s = *(environ + i);
    }
    return 0;
}
```

Expected: the program prints only FOO=BAR.

Actual: the program prints all variables in the parent environment.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to