summaryrefslogtreecommitdiffstats
path: root/BaseTools
diff options
context:
space:
mode:
authorRebecca Cran <rebecca@bsdio.com>2021-06-13 11:43:01 +0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2021-06-25 04:15:40 +0000
commit17143c4837393d42c484b42d1789b85b2cff1aaf (patch)
tree98ffd19118864a532c47d3a68387e27e5a3c68c7 /BaseTools
parentf0a3f6d9c30bf0926959a23c1454053a9df5ae9d (diff)
downloadedk2-17143c4837393d42c484b42d1789b85b2cff1aaf.tar.gz
edk2-17143c4837393d42c484b42d1789b85b2cff1aaf.tar.bz2
edk2-17143c4837393d42c484b42d1789b85b2cff1aaf.zip
BaseTools: Reset ERRORLEVEL in toolsetup.bat after edk2basetools check
When using the in-source BaseTools, edksetup.bat will exit with an ERRORLEVEL of 1 because the line in toolsetup.bat "%PYTHON_COMMAND% -c "import edk2basetools" >NUL 2>NUL" fails. Ensure ERRORLEVEL is set to 0 when edksetup.bat or toolsetup.bat is successfully run. Signed-off-by: Rebecca Cran <rebecca@bsdio.com> Reviewed-by: Bob Feng <bob.c.feng@intel.com> Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
Diffstat (limited to 'BaseTools')
-rwxr-xr-xBaseTools/toolsetup.bat2
1 files changed, 2 insertions, 0 deletions
diff --git a/BaseTools/toolsetup.bat b/BaseTools/toolsetup.bat
index 4fcff31879..58fd26a4b5 100755
--- a/BaseTools/toolsetup.bat
+++ b/BaseTools/toolsetup.bat
@@ -401,6 +401,8 @@ goto end
if %ERRORLEVEL% EQU 0 (
goto use_pip_basetools
) else (
+ REM reset ERRORLEVEL
+ type nul>nul
goto use_builtin_basetools
)