mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-01 16:43:38 +00:00
cmd: mkdir: Set errorlevel on invalid argument.
This commit is contained in:
parent
15ce9a5784
commit
3cd864bdf8
|
@ -537,6 +537,7 @@ void WCMD_create_dir (WCHAR *command) {
|
|||
if (!argN) break;
|
||||
if (!create_full_path(thisArg)) {
|
||||
WCMD_print_error ();
|
||||
errorlevel = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -485,18 +485,18 @@ if exist foo (rmdir foo & echo dir created
|
|||
echo %ErrorLevel%
|
||||
rem Invalid chars
|
||||
mkdir ?
|
||||
echo %ErrorLevel%
|
||||
echo mkdir ? gives errorlevel %ErrorLevel%
|
||||
call :setError 0
|
||||
mkdir ?\foo
|
||||
echo %ErrorLevel%
|
||||
echo mkdir ?\foo gives errorlevel %ErrorLevel%
|
||||
call :setError 0
|
||||
mkdir foo\?
|
||||
echo %ErrorLevel%
|
||||
echo mkdir foo\? gives errorlevel %ErrorLevel%
|
||||
if exist foo (rmdir foo & echo ok, foo created
|
||||
) else ( echo foo not created )
|
||||
call :setError 0
|
||||
mkdir foo\bar\?
|
||||
echo %ErrorLevel%
|
||||
echo mkdir foo\bar\? gives errorlevel %ErrorLevel%
|
||||
call :setError 0
|
||||
if not exist foo (
|
||||
echo bad, foo not created
|
||||
|
|
|
@ -277,11 +277,11 @@ del /q * succeeded on file2.dat
|
|||
0
|
||||
dir created
|
||||
0
|
||||
@todo_wine@1
|
||||
@todo_wine@1
|
||||
@todo_wine@1
|
||||
mkdir ? gives errorlevel 1
|
||||
mkdir ?\foo gives errorlevel 1
|
||||
mkdir foo\? gives errorlevel 1
|
||||
@todo_wine@ok, foo created
|
||||
@todo_wine@1
|
||||
mkdir foo\bar\? gives errorlevel 1
|
||||
@todo_wine@ok, foo\bar created
|
||||
foo created
|
||||
bar created
|
||||
|
|
Loading…
Reference in a new issue