Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3924)

Unified Diff: build/toolchain/wrapper_utils.py

Issue 2617283002: Add Clang static analyzer to Clang toolchain defs in GN (Closed)
Patch Set: rebase Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/toolchain/mac/BUILD.gn ('k') | docs/clang_static_analyzer.md » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/toolchain/wrapper_utils.py
diff --git a/build/toolchain/wrapper_utils.py b/build/toolchain/wrapper_utils.py
index 163a292c165cc0b484804aebfa693c02e5e7e871..467d85d9e2a74b2dda23be02fe3eda86071d396e 100644
--- a/build/toolchain/wrapper_utils.py
+++ b/build/toolchain/wrapper_utils.py
@@ -92,14 +92,13 @@ def ExtractResourceIdsFromPragmaWarnings(text):
return used_resources
-def CaptureCommandStderr(command):
+def CaptureCommandStderr(command, env=None):
"""Returns the stderr of a command.
Args:
- args: A list containing the command and arguments.
- cwd: The working directory from where the command should be made.
+ command: A list containing the command and arguments.
env: Environment variables for the new process.
"""
- child = subprocess.Popen(command, stderr=subprocess.PIPE)
+ child = subprocess.Popen(command, stderr=subprocess.PIPE, env=env)
_, stderr = child.communicate()
return child.returncode, stderr
« no previous file with comments | « build/toolchain/mac/BUILD.gn ('k') | docs/clang_static_analyzer.md » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698