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
14a68405
Commit
14a68405
authored
Oct 22, 2009
by
Eric Pouech
Committed by
Alexandre Julliard
Oct 23, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winmm: Simply use kernel32.{Release|Restore}ThunkLock instead of using 16bit convolutions.
parent
9709d1c6
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
13 deletions
+4
-13
mmsystem.c
dlls/winmm/mmsystem.c
+0
-4
winemm.h
dlls/winmm/winemm.h
+0
-2
winmm.c
dlls/winmm/winmm.c
+4
-7
No files found.
dlls/winmm/mmsystem.c
View file @
14a68405
...
...
@@ -90,16 +90,12 @@ BOOL WINAPI MMSYSTEM_LibMain(DWORD fdwReason, HINSTANCE hinstDLL, WORD ds,
pFnOpenDriver16
=
DRIVER_OpenDriver16
;
pFnCloseDriver16
=
DRIVER_CloseDriver16
;
pFnSendMessage16
=
DRIVER_SendMessage16
;
pFnReleaseThunkLock
=
ReleaseThunkLock
;
pFnRestoreThunkLock
=
RestoreThunkLock
;
MMDRV_Init16
();
break
;
case
DLL_PROCESS_DETACH
:
pFnOpenDriver16
=
NULL
;
pFnCloseDriver16
=
NULL
;
pFnSendMessage16
=
NULL
;
pFnReleaseThunkLock
=
NULL
;
pFnRestoreThunkLock
=
NULL
;
/* FIXME: add equivalent for MMDRV_Init16() */
break
;
case
DLL_THREAD_ATTACH
:
...
...
dlls/winmm/winemm.h
View file @
14a68405
...
...
@@ -201,8 +201,6 @@ extern WINMM_MapType (*pFnMciMapMsg32WTo16)(WORD,WORD,DWORD,DWORD_PTR*);
extern
WINMM_MapType
(
*
pFnMciUnMapMsg32WTo16
)(
WORD
,
WORD
,
DWORD
,
DWORD_PTR
);
extern
LRESULT
(
*
pFnCallMMDrvFunc16
)(
DWORD
/* in fact FARPROC16 */
,
WORD
,
WORD
,
LONG
,
LONG
,
LONG
);
extern
unsigned
(
*
pFnLoadMMDrvFunc16
)(
LPCSTR
,
LPWINE_DRIVER
,
LPWINE_MM_DRIVER
);
extern
void
(
WINAPI
*
pFnReleaseThunkLock
)(
DWORD
*
);
extern
void
(
WINAPI
*
pFnRestoreThunkLock
)(
DWORD
);
/* GetDriverFlags() returned bits is not documented (nor the call itself)
* Here are Wine only definitions of the bits
...
...
dlls/winmm/winmm.c
View file @
14a68405
...
...
@@ -57,9 +57,6 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
winmm
);
void
(
WINAPI
*
pFnReleaseThunkLock
)(
DWORD
*
);
void
(
WINAPI
*
pFnRestoreThunkLock
)(
DWORD
);
/* ========================================================================
* G L O B A L S E T T I N G S
* ========================================================================*/
...
...
@@ -1748,9 +1745,9 @@ static BOOL MMSYSTEM_MidiStream_PostMessage(WINE_MIDIStream* lpMidiStrm, WORD ms
if
(
PostThreadMessageA
(
lpMidiStrm
->
dwThreadID
,
msg
,
pmt1
,
pmt2
))
{
DWORD
count
;
if
(
pFnReleaseThunkLock
)
pFn
ReleaseThunkLock
(
&
count
);
ReleaseThunkLock
(
&
count
);
WaitForSingleObject
(
lpMidiStrm
->
hEvent
,
INFINITE
);
if
(
pFnRestoreThunkLock
)
pFn
RestoreThunkLock
(
count
);
RestoreThunkLock
(
count
);
}
else
{
WARN
(
"bad PostThreadMessageA
\n
"
);
return
FALSE
;
...
...
@@ -1836,9 +1833,9 @@ MMRESULT WINAPI midiStreamOpen(HMIDISTRM* lphMidiStrm, LPUINT lpuDeviceID,
* (meaning the Win16Lock is set), so that it's released and the 32 bit thread running
* MMSYSTEM_MidiStreamPlayer can acquire Win16Lock to create its queue.
*/
if
(
pFnReleaseThunkLock
)
pFn
ReleaseThunkLock
(
&
count
);
ReleaseThunkLock
(
&
count
);
WaitForSingleObject
(
lpMidiStrm
->
hEvent
,
INFINITE
);
if
(
pFnRestoreThunkLock
)
pFn
RestoreThunkLock
(
count
);
RestoreThunkLock
(
count
);
}
TRACE
(
"=> (%u/%d) hMidi=%p ret=%d lpMidiStrm=%p
\n
"
,
...
...
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