Before this change we were overriding the launch info environment with the target environment. This meant that the environment variables passed to `process launch --environment <>` were lost. Instead of replacing the environment, we should merge them. Differential revision: https://reviews.llvm.org/D61864 llvm-svn: 360612
8 lines
143 B
C++
8 lines
143 B
C++
#include <cstdlib>
|
|
#include <iostream>
|
|
|
|
int main() {
|
|
if (const char *env_p = std::getenv("FOO"))
|
|
std::cout << "FOO=" << env_p << '\n';
|
|
}
|