Don't pass environment variables with "\n" to LightProcesses
A recent diff started (correctly) passing the environment through to child processes. It turns out our LightProcess implementation can't handle environment variables with new lines in them, so (for now) strip out any such variables.
Esse commit está contido em:
@@ -814,7 +814,10 @@ Variant f_proc_open(CStrRef cmd, CArrRef descriptorspec, VRefParam pipes,
|
||||
nvpair += iter.first().toString();
|
||||
nvpair += '=';
|
||||
nvpair += iter.second().toString();
|
||||
envs.push_back(nvpair.detach().c_str());
|
||||
string tmp = nvpair.detach().c_str();
|
||||
if (tmp.find('\n') == string::npos) {
|
||||
envs.push_back(tmp);
|
||||
}
|
||||
}
|
||||
|
||||
child = LightProcess::proc_open(cmd.c_str(), created, intended,
|
||||
|
||||
Referência em uma Nova Issue
Bloquear um usuário