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
12d37412
Commit
12d37412
authored
Aug 01, 2013
by
Piotr Caban
Committed by
Alexandre Julliard
Aug 01, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
scrrun: Fix IFile::get_Attributes tests and implementation.
parent
00289d5b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
5 deletions
+7
-5
filesystem.c
dlls/scrrun/filesystem.c
+3
-1
filesystem.c
dlls/scrrun/tests/filesystem.c
+4
-4
No files found.
dlls/scrrun/filesystem.c
View file @
12d37412
...
...
@@ -791,7 +791,9 @@ static HRESULT WINAPI file_get_Attributes(IFile *iface, FileAttribute *pfa)
if
(
fa
==
INVALID_FILE_ATTRIBUTES
)
return
create_error
(
GetLastError
());
*
pfa
=
fa
&
~
FILE_ATTRIBUTE_NORMAL
;
*
pfa
=
fa
&
(
FILE_ATTRIBUTE_READONLY
|
FILE_ATTRIBUTE_HIDDEN
|
FILE_ATTRIBUTE_SYSTEM
|
FILE_ATTRIBUTE_DIRECTORY
|
FILE_ATTRIBUTE_ARCHIVE
|
FILE_ATTRIBUTE_REPARSE_POINT
|
FILE_ATTRIBUTE_COMPRESSED
);
return
S_OK
;
}
...
...
dlls/scrrun/tests/filesystem.c
View file @
12d37412
...
...
@@ -478,9 +478,7 @@ static void test_GetFile(void)
hr
=
IFileSystem3_GetFile
(
fs3
,
NULL
,
&
file
);
ok
(
hr
==
E_INVALIDARG
,
"GetFile returned %x, expected E_INVALIDARG
\n
"
,
hr
);
hf
=
CreateFileW
(
path
,
GENERIC_WRITE
,
0
,
NULL
,
OPEN_EXISTING
,
FILE_ATTRIBUTE_NORMAL
,
NULL
);
if
(
hf
!=
INVALID_HANDLE_VALUE
)
{
CloseHandle
(
hf
);
if
(
GetFileAttributesW
(
path
)
!=
INVALID_FILE_ATTRIBUTES
)
{
skip
(
"File already exists, skipping GetFile tests
\n
"
);
SysFreeString
(
path
);
return
;
...
...
@@ -503,7 +501,9 @@ static void test_GetFile(void)
ok
(
hr
==
S_OK
,
"GetFile returned %x, expected S_OK
\n
"
,
hr
);
hr
=
IFile_get_Attributes
(
file
,
&
fa
);
gfa
=
GetFileAttributesW
(
get_file
)
&
~
FILE_ATTRIBUTE_NORMAL
;
gfa
=
GetFileAttributesW
(
get_file
)
&
(
FILE_ATTRIBUTE_READONLY
|
FILE_ATTRIBUTE_HIDDEN
|
FILE_ATTRIBUTE_SYSTEM
|
FILE_ATTRIBUTE_DIRECTORY
|
FILE_ATTRIBUTE_ARCHIVE
|
FILE_ATTRIBUTE_REPARSE_POINT
|
FILE_ATTRIBUTE_COMPRESSED
);
ok
(
hr
==
S_OK
,
"get_Attributes returned %x, expected S_OK
\n
"
,
hr
);
ok
(
fa
==
gfa
,
"fa = %x, expected %x
\n
"
,
fa
,
gfa
);
...
...
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