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
b1e007e3
Commit
b1e007e3
authored
Jun 18, 2009
by
Paul Vriens
Committed by
Alexandre Julliard
Jun 19, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shell32/tests: Fix a test failure on Vista and higher.
parent
fb37e89a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
shlfolder.c
dlls/shell32/tests/shlfolder.c
+6
-6
No files found.
dlls/shell32/tests/shlfolder.c
View file @
b1e007e3
...
@@ -1558,7 +1558,7 @@ static void testSHGetFolderPathAndSubDirA(void)
...
@@ -1558,7 +1558,7 @@ static void testSHGetFolderPathAndSubDirA(void)
static
char
toolongpath
[
MAX_PATH
+
1
];
static
char
toolongpath
[
MAX_PATH
+
1
];
if
(
!
pSHGetFolderPathA
)
{
if
(
!
pSHGetFolderPathA
)
{
skip
(
"SHGetFolderPathA not present!
\n
"
);
win_
skip
(
"SHGetFolderPathA not present!
\n
"
);
return
;
return
;
}
}
if
(
FAILED
(
pSHGetFolderPathA
(
NULL
,
CSIDL_LOCAL_APPDATA
,
NULL
,
SHGFP_TYPE_CURRENT
,
appdata
)))
if
(
FAILED
(
pSHGetFolderPathA
(
NULL
,
CSIDL_LOCAL_APPDATA
,
NULL
,
SHGFP_TYPE_CURRENT
,
appdata
)))
...
@@ -1580,16 +1580,13 @@ static void testSHGetFolderPathAndSubDirA(void)
...
@@ -1580,16 +1580,13 @@ static void testSHGetFolderPathAndSubDirA(void)
skip
(
"RemoveDirectoryA(%s) failed with error %u
\n
"
,
testpath
,
GetLastError
());
skip
(
"RemoveDirectoryA(%s) failed with error %u
\n
"
,
testpath
,
GetLastError
());
return
;
return
;
}
}
for
(
i
=
0
;
i
<
MAX_PATH
;
i
++
)
toolongpath
[
i
]
=
'0'
+
i
%
10
;
toolongpath
[
MAX_PATH
]
=
'\0'
;
/* test invalid second parameter */
/* test invalid second parameter */
ret
=
pSHGetFolderPathAndSubDirA
(
NULL
,
CSIDL_FLAG_DONT_VERIFY
|
0xff
,
NULL
,
SHGFP_TYPE_CURRENT
,
wine
,
testpath
);
ret
=
pSHGetFolderPathAndSubDirA
(
NULL
,
CSIDL_FLAG_DONT_VERIFY
|
0xff
,
NULL
,
SHGFP_TYPE_CURRENT
,
wine
,
testpath
);
ok
(
E_INVALIDARG
==
ret
,
"expected E_INVALIDARG, got %x
\n
"
,
ret
);
ok
(
E_INVALIDARG
==
ret
,
"expected E_INVALIDARG, got %x
\n
"
,
ret
);
/* test
invalid fo
rth parameter */
/* test
fou
rth parameter */
ret
=
pSHGetFolderPathAndSubDirA
(
NULL
,
CSIDL_FLAG_DONT_VERIFY
|
CSIDL_LOCAL_APPDATA
,
NULL
,
2
,
wine
,
testpath
);
ret
=
pSHGetFolderPathAndSubDirA
(
NULL
,
CSIDL_FLAG_DONT_VERIFY
|
CSIDL_LOCAL_APPDATA
,
NULL
,
2
,
wine
temp
,
testpath
);
switch
(
ret
)
{
switch
(
ret
)
{
case
S_OK
:
/* winvista */
case
S_OK
:
/* winvista */
ok
(
!
strncmp
(
appdata
,
testpath
,
strlen
(
appdata
)),
ok
(
!
strncmp
(
appdata
,
testpath
,
strlen
(
appdata
)),
...
@@ -1619,6 +1616,9 @@ static void testSHGetFolderPathAndSubDirA(void)
...
@@ -1619,6 +1616,9 @@ static void testSHGetFolderPathAndSubDirA(void)
ok
(
S_OK
==
ret
,
"expected S_OK, got %x
\n
"
,
ret
);
ok
(
S_OK
==
ret
,
"expected S_OK, got %x
\n
"
,
ret
);
ok
(
!
lstrcmpA
(
appdata
,
testpath
),
"expected %s, got %s
\n
"
,
appdata
,
testpath
);
ok
(
!
lstrcmpA
(
appdata
,
testpath
),
"expected %s, got %s
\n
"
,
appdata
,
testpath
);
for
(
i
=
0
;
i
<
MAX_PATH
;
i
++
)
toolongpath
[
i
]
=
'0'
+
i
%
10
;
toolongpath
[
MAX_PATH
]
=
'\0'
;
ret
=
pSHGetFolderPathAndSubDirA
(
NULL
,
CSIDL_FLAG_DONT_VERIFY
|
CSIDL_LOCAL_APPDATA
,
NULL
,
SHGFP_TYPE_CURRENT
,
toolongpath
,
testpath
);
ret
=
pSHGetFolderPathAndSubDirA
(
NULL
,
CSIDL_FLAG_DONT_VERIFY
|
CSIDL_LOCAL_APPDATA
,
NULL
,
SHGFP_TYPE_CURRENT
,
toolongpath
,
testpath
);
ok
(
HRESULT_FROM_WIN32
(
ERROR_FILENAME_EXCED_RANGE
)
==
ret
,
ok
(
HRESULT_FROM_WIN32
(
ERROR_FILENAME_EXCED_RANGE
)
==
ret
,
"expected %x, got %x
\n
"
,
HRESULT_FROM_WIN32
(
ERROR_FILENAME_EXCED_RANGE
),
ret
);
"expected %x, got %x
\n
"
,
HRESULT_FROM_WIN32
(
ERROR_FILENAME_EXCED_RANGE
),
ret
);
...
...
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