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
bd3f27ab
Commit
bd3f27ab
authored
Mar 19, 2020
by
Nikolay Sivov
Committed by
Alexandre Julliard
Mar 19, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mfplat: Fix scanline pointer returned with Lock2D().
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
b9eb121e
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
buffer.c
dlls/mfplat/buffer.c
+1
-1
mfplat.c
dlls/mfplat/tests/mfplat.c
+7
-1
No files found.
dlls/mfplat/buffer.c
View file @
bd3f27ab
...
...
@@ -340,7 +340,7 @@ static HRESULT memory_2d_buffer_lock(struct memory_buffer *buffer, BYTE **scanli
else
{
++
buffer
->
_2d
.
locks
;
*
scanline0
=
buffer
->
data
;
*
scanline0
=
buffer
->
_2d
.
scanline0
;
*
pitch
=
buffer
->
_2d
.
pitch
;
if
(
buffer_start
)
*
buffer_start
=
buffer
->
data
;
...
...
dlls/mfplat/tests/mfplat.c
View file @
bd3f27ab
...
...
@@ -4694,7 +4694,7 @@ static void test_MFCreate2DMediaBuffer(void)
IMF2DBuffer2
*
_2dbuffer2
;
IMF2DBuffer
*
_2dbuffer
;
IMFMediaBuffer
*
buffer
;
int
i
,
pitch
;
int
i
,
pitch
,
pitch2
;
HRESULT
hr
;
BOOL
ret
;
...
...
@@ -4898,6 +4898,12 @@ static void test_MFCreate2DMediaBuffer(void)
hr
=
IMF2DBuffer_Lock2D
(
_2dbuffer
,
&
data
,
&
pitch
);
ok
(
hr
==
S_OK
,
"Failed to lock buffer, hr %#x.
\n
"
,
hr
);
hr
=
IMF2DBuffer_GetScanline0AndPitch
(
_2dbuffer
,
&
data2
,
&
pitch2
);
ok
(
hr
==
S_OK
,
"Failed to get scanline, hr %#x.
\n
"
,
hr
);
ok
(
data2
==
data
,
"Unexpected data pointer.
\n
"
);
ok
(
pitch
==
pitch2
,
"Unexpected pitch.
\n
"
);
hr
=
IMF2DBuffer_Unlock2D
(
_2dbuffer
);
ok
(
hr
==
S_OK
,
"Failed to unlock buffer, hr %#x.
\n
"
,
hr
);
...
...
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