[CMD] Code formatting in SubstituteVar().

This commit is contained in:
Hermès Bélusca-Maïto 2020-09-19 18:48:51 +02:00
parent cdc8e45b48
commit 5cf0517be1
No known key found for this signature in database
GPG key ID: 3B2539C65E7B93D0

View file

@ -1363,7 +1363,6 @@ do { \
if (!*Src || *Src == _T('\r') || *Src == _T('\n'))
goto bad_subst;
{
if (bc && Delim == _T('%'))
{
UINT NameLen;
@ -1487,19 +1486,17 @@ do { \
APPEND(&Var[LastMatch], VarLength - LastMatch);
}
goto success;
success:
*SrcIncLen = (Src - Start);
*DestIncLen = (Dest - End);
return TRUE;
bad_subst:
Src = SubstStart;
/* Only if no batch context active do we echo the delimiter */
if (!bc)
APPEND1(Delim);
}
success:
*SrcIncLen = (Src - Start);
*DestIncLen = (Dest - End);
return TRUE;
goto success;
too_long:
ConOutResPrintf(STRING_ALIAS_ERROR);