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
3ea66d60
Commit
3ea66d60
authored
Jun 10, 2009
by
Rico Schüller
Committed by
Alexandre Julliard
Jun 11, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Don't allow a negative lock_count in buffer_Unmap.
parent
9e5d07bb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
0 deletions
+10
-0
buffer.c
dlls/wined3d/buffer.c
+10
-0
No files found.
dlls/wined3d/buffer.c
View file @
3ea66d60
...
...
@@ -985,6 +985,16 @@ static HRESULT STDMETHODCALLTYPE buffer_Unmap(IWineD3DBuffer *iface)
TRACE
(
"(%p)
\n
"
,
This
);
/* In the case that the number of Unmap calls > the
* number of Map calls, d3d returns always D3D_OK.
* This is also needed to prevent Map from returning garbage on
* the next call (this will happen if the lock_count is < 0). */
if
(
This
->
lock_count
==
0
)
{
TRACE
(
"Unmap called without a previous Map call!
\n
"
);
return
WINED3D_OK
;
}
if
(
InterlockedDecrement
(
&
This
->
lock_count
))
{
/* Delay loading the buffer until everything is unlocked */
...
...
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