Fossil SCM

Improve the MSVC build tool sub-routine 'fn_UnsetVariable'.

mistachkin 2016-02-06 02:27 trunk
Commit 4c163cd71560883666b3fdcb28a0a565c1401b38
1 file changed +6 -2
--- win/buildmsvc.bat
+++ win/buildmsvc.bat
@@ -259,16 +259,20 @@
259259
CALL :fn_UnsetVariable PFILES_SDK71A
260260
SET NMAKE_ARGS=%NMAKE_ARGS% FOSSIL_ENABLE_WINXP=1
261261
GOTO :EOF
262262
263263
:fn_UnsetVariable
264
+ SETLOCAL
264265
SET VALUE=%1
265266
IF DEFINED VALUE (
266
- SET %VALUE%=
267267
SET VALUE=
268
- CALL :fn_ResetErrorLevel
268
+ ENDLOCAL
269
+ SET %VALUE%=
270
+ ) ELSE (
271
+ ENDLOCAL
269272
)
273
+ CALL :fn_ResetErrorLevel
270274
GOTO :EOF
271275
272276
:fn_ResetErrorLevel
273277
VERIFY > NUL
274278
GOTO :EOF
275279
--- win/buildmsvc.bat
+++ win/buildmsvc.bat
@@ -259,16 +259,20 @@
259 CALL :fn_UnsetVariable PFILES_SDK71A
260 SET NMAKE_ARGS=%NMAKE_ARGS% FOSSIL_ENABLE_WINXP=1
261 GOTO :EOF
262
263 :fn_UnsetVariable
 
264 SET VALUE=%1
265 IF DEFINED VALUE (
266 SET %VALUE%=
267 SET VALUE=
268 CALL :fn_ResetErrorLevel
 
 
 
269 )
 
270 GOTO :EOF
271
272 :fn_ResetErrorLevel
273 VERIFY > NUL
274 GOTO :EOF
275
--- win/buildmsvc.bat
+++ win/buildmsvc.bat
@@ -259,16 +259,20 @@
259 CALL :fn_UnsetVariable PFILES_SDK71A
260 SET NMAKE_ARGS=%NMAKE_ARGS% FOSSIL_ENABLE_WINXP=1
261 GOTO :EOF
262
263 :fn_UnsetVariable
264 SETLOCAL
265 SET VALUE=%1
266 IF DEFINED VALUE (
 
267 SET VALUE=
268 ENDLOCAL
269 SET %VALUE%=
270 ) ELSE (
271 ENDLOCAL
272 )
273 CALL :fn_ResetErrorLevel
274 GOTO :EOF
275
276 :fn_ResetErrorLevel
277 VERIFY > NUL
278 GOTO :EOF
279

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button