Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
196fb10c
Commit
196fb10c
authored
Jun 15, 2007
by
Jason Edmeades
Committed by
Alexandre Julliard
Jun 18, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cmd.exe: for loop by default only matches files.
parent
54d890ca
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
builtins.c
programs/cmd/builtins.c
+6
-0
No files found.
programs/cmd/builtins.c
View file @
196fb10c
...
@@ -593,6 +593,7 @@ void WCMD_for (WCHAR *p, CMD_LIST **cmdList) {
...
@@ -593,6 +593,7 @@ void WCMD_for (WCHAR *p, CMD_LIST **cmdList) {
WCHAR
variable
[
4
];
WCHAR
variable
[
4
];
WCHAR
*
firstCmd
;
WCHAR
*
firstCmd
;
int
thisDepth
;
int
thisDepth
;
BOOL
isDirs
=
FALSE
;
/* Check:
/* Check:
the first line includes the % variable name as first parm
the first line includes the % variable name as first parm
...
@@ -667,10 +668,15 @@ void WCMD_for (WCHAR *p, CMD_LIST **cmdList) {
...
@@ -667,10 +668,15 @@ void WCMD_for (WCHAR *p, CMD_LIST **cmdList) {
hff
=
FindFirstFile
(
item
,
&
fd
);
hff
=
FindFirstFile
(
item
,
&
fd
);
if
(
hff
!=
INVALID_HANDLE_VALUE
)
{
if
(
hff
!=
INVALID_HANDLE_VALUE
)
{
do
{
do
{
BOOL
isDirectory
=
(
fd
.
dwFileAttributes
&
FILE_ATTRIBUTE_DIRECTORY
);
if
((
isDirs
&&
isDirectory
)
||
(
!
isDirs
&&
!
isDirectory
))
{
thisCmdStart
=
cmdStart
;
thisCmdStart
=
cmdStart
;
WINE_TRACE
(
"Processing FOR filename %s
\n
"
,
wine_dbgstr_w
(
fd
.
cFileName
));
WINE_TRACE
(
"Processing FOR filename %s
\n
"
,
wine_dbgstr_w
(
fd
.
cFileName
));
WCMD_part_execute
(
&
thisCmdStart
,
firstCmd
,
variable
,
WCMD_part_execute
(
&
thisCmdStart
,
firstCmd
,
variable
,
fd
.
cFileName
,
FALSE
,
TRUE
);
fd
.
cFileName
,
FALSE
,
TRUE
);
}
}
while
(
FindNextFile
(
hff
,
&
fd
)
!=
0
);
}
while
(
FindNextFile
(
hff
,
&
fd
)
!=
0
);
FindClose
(
hff
);
FindClose
(
hff
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment