Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
b00be289
Commit
b00be289
authored
Mar 26, 2019
by
Nikolay Sivov
Committed by
Alexandre Julliard
Mar 26, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mfplat: Return capabilities for file stream.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
b74b5991
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
1 deletion
+5
-1
main.c
dlls/mfplat/main.c
+5
-0
mfplat.c
dlls/mfplat/tests/mfplat.c
+0
-1
No files found.
dlls/mfplat/main.c
View file @
b00be289
...
...
@@ -2823,6 +2823,7 @@ static const IMFGetServiceVtbl bytestream_file_getservice_vtbl =
HRESULT
WINAPI
MFCreateFile
(
MF_FILE_ACCESSMODE
accessmode
,
MF_FILE_OPENMODE
openmode
,
MF_FILE_FLAGS
flags
,
LPCWSTR
url
,
IMFByteStream
**
bytestream
)
{
DWORD
capabilities
=
MFBYTESTREAM_IS_SEEKABLE
|
MFBYTESTREAM_DOES_NOT_USE_NETWORK
;
struct
bytestream
*
object
;
DWORD
fileaccessmode
=
0
;
DWORD
filesharemode
=
FILE_SHARE_READ
;
...
...
@@ -2838,12 +2839,15 @@ HRESULT WINAPI MFCreateFile(MF_FILE_ACCESSMODE accessmode, MF_FILE_OPENMODE open
{
case
MF_ACCESSMODE_READ
:
fileaccessmode
=
GENERIC_READ
;
capabilities
|=
MFBYTESTREAM_IS_READABLE
;
break
;
case
MF_ACCESSMODE_WRITE
:
fileaccessmode
=
GENERIC_WRITE
;
capabilities
|=
MFBYTESTREAM_IS_WRITABLE
;
break
;
case
MF_ACCESSMODE_READWRITE
:
fileaccessmode
=
GENERIC_READ
|
GENERIC_WRITE
;
capabilities
|=
(
MFBYTESTREAM_IS_READABLE
|
MFBYTESTREAM_IS_WRITABLE
);
break
;
}
...
...
@@ -2897,6 +2901,7 @@ HRESULT WINAPI MFCreateFile(MF_FILE_ACCESSMODE accessmode, MF_FILE_OPENMODE open
object
->
write_callback
.
lpVtbl
=
&
bytestream_file_write_callback_vtbl
;
InitializeCriticalSection
(
&
object
->
cs
);
list_init
(
&
object
->
pending
);
object
->
capabilities
=
capabilities
;
object
->
hfile
=
file
;
if
(
GetFileTime
(
file
,
NULL
,
NULL
,
&
writetime
))
...
...
dlls/mfplat/tests/mfplat.c
View file @
b00be289
...
...
@@ -1153,7 +1153,6 @@ static void test_file_stream(void)
ok
(
hr
==
S_OK
,
"Failed to get stream capabilities, hr %#x.
\n
"
,
hr
);
if
(
is_win8_plus
)
{
todo_wine
ok
(
caps
==
(
MFBYTESTREAM_IS_READABLE
|
MFBYTESTREAM_IS_SEEKABLE
|
MFBYTESTREAM_DOES_NOT_USE_NETWORK
),
"Unexpected caps %#x.
\n
"
,
caps
);
}
...
...
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