So I'm making this logger batch which save a log everytime it opens and a part of the code seems to be wierd..
Here's the code:
Code: Select all
set av=false
set avv=false
if %av%==false (
if %avv%==true goto a
if exist E:\authorize (
::cls
set pw=false
set pwc=false
echo What's the password ?
set /p pw=
cd E:\authorize
< pw (
set /p pwc=
)
pause
if %pw%==%pwc% (
cd C:\Users\Admin\AppData\Roaming\WCMP\logs
< location (
set /p loglocation=
)
cd %loglocation%
< log.txt (
set /p timedayll=
)
pause
del log.txt
echo %timedayll%>log.txt
echo Access Authorized>>log.txt
)
)
set avv=false
)
Every directory exists and (I think) all variables are set too.
I don't know what's going on with this but the cmd window is always crashing with this output
Code: Select all
C:\>code.bat
C:\>set av=false
C:\>set avv=false
A sintaxe do comando está incorrecta (what is bettewn the "()" is not part of the output, that sentence probably means "The command's Sintax is incorrect").
C:\>if == (
C:\>
Could anyone please help me in this, I really don't understand what's happening.
If you need any other information about the code don't hesitate to ask.
Thanks for reading
