Fixed bug where certain USB security keys would cause a popup about "No
disk in \HardDrive1\DR1".
This commit is contained in:
2Shirt 2014-07-20 15:20:11 -07:00
parent ff4b3ff679
commit 7a9fd08c56

View file

@ -44,11 +44,14 @@ set year=%date:~10,4%
:FindAloha :FindAloha
for %%d in (c d e f g h i j k l m n o p q r s t u v w x y z) do ( for %%d in (c d e f g h i j k l m n o p q r s t u v w x y z) do (
dir %%d:>nul 2>nul
if "!errorlevel!" equ "0" (
if exist "%%d:\AlohaQS\*.*" ( if exist "%%d:\AlohaQS\*.*" (
set src=%%d:\AlohaQS set src=%%d:\AlohaQS
goto FindSevenZip goto FindSevenZip
) )
) )
)
rem Not found rem Not found
goto AlohaNotFound goto AlohaNotFound
@ -241,11 +244,14 @@ cd /d "%src%"
:CopyBackup :CopyBackup
for %%d in (c d e f g h i j k l m n o p q r s t u v w x y z) do ( for %%d in (c d e f g h i j k l m n o p q r s t u v w x y z) do (
dir %%d:>nul 2>nul
if "!errorlevel!" equ "0" (
if exist "%%d:\%backup%\*.*" ( if exist "%%d:\%backup%\*.*" (
mkdir "%%d:\%backup%\%subdir%" 2>nul mkdir "%%d:\%backup%\%subdir%" 2>nul
copy "%tmp%\%filename%" "%%d:\%backup%\%subdir%\%filename%" /y copy "%tmp%\%filename%" "%%d:\%backup%\%subdir%\%filename%" /y
) )
) )
)
:Cleanup :Cleanup
del /q "%tmp%\%filename%" del /q "%tmp%\%filename%"
@ -292,4 +298,6 @@ echo Press any key to exit...
pause>nul pause>nul
:Done :Done
popd
endlocal
color color