Do not print to console for which command
The command which would print warnings on some platform. Redirect both stdout and stderr to /dev/null while running the command. Signed-off-by: Jiadong Zhu <Jiadong.Zhu@amd.com> Change-Id: Ibc377681a31a14a3e306ab4fcb14d8d0c853fa86
Dieser Commit ist enthalten in:
committet von
David Yat Sin
Ursprung
29dfe7d0fc
Commit
d1efacb47f
+1
-1
@@ -248,7 +248,7 @@ pair<string, int> exec(const char* cmd) {
|
||||
}
|
||||
|
||||
static void DetectWSLEnvironment() {
|
||||
auto process_ret = exec("which wslinfo");
|
||||
auto process_ret = exec("which wslinfo > /dev/null 2>&1");
|
||||
if (process_ret.second)
|
||||
return;
|
||||
|
||||
|
||||
In neuem Issue referenzieren
Einen Benutzer sperren