Christian Costa : dmusic: Improve IDirectMusicPortImpl_DownloadInstrument stub.
Alexandre Julliard
julliard at winehq.org
Mon Dec 22 10:19:53 CST 2008
Module: wine
Branch: master
Commit: ceb87f98a236bb82b5e3ac2841b351df24d4ec34
URL: http://source.winehq.org/git/wine.git/?a=commit;h=ceb87f98a236bb82b5e3ac2841b351df24d4ec34
Author: Christian Costa <titan.costa at wanadoo.fr>
Date: Mon Dec 22 13:40:58 2008 +0100
dmusic: Improve IDirectMusicPortImpl_DownloadInstrument stub.
---
dlls/dmusic/port.c | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/dlls/dmusic/port.c b/dlls/dmusic/port.c
index 7773d28..5264f58 100644
--- a/dlls/dmusic/port.c
+++ b/dlls/dmusic/port.c
@@ -88,8 +88,13 @@ static HRESULT WINAPI IDirectMusicPortImpl_Read (LPDIRECTMUSICPORT iface, LPDIRE
static HRESULT WINAPI IDirectMusicPortImpl_DownloadInstrument (LPDIRECTMUSICPORT iface, IDirectMusicInstrument* pInstrument, IDirectMusicDownloadedInstrument** ppDownloadedInstrument, DMUS_NOTERANGE* pNoteRanges, DWORD dwNumNoteRanges) {
IDirectMusicPortImpl *This = (IDirectMusicPortImpl *)iface;
+
FIXME("(%p, %p, %p, %p, %d): stub\n", This, pInstrument, ppDownloadedInstrument, pNoteRanges, dwNumNoteRanges);
- return S_OK;
+
+ if (!pInstrument || !ppDownloadedInstrument || (dwNumNoteRanges && !pNoteRanges))
+ return E_POINTER;
+
+ return DMUSIC_CreateDirectMusicDownloadedInstrumentImpl(&IID_IDirectMusicDownloadedInstrument, (LPVOID*)ppDownloadedInstrument, NULL);
}
static HRESULT WINAPI IDirectMusicPortImpl_UnloadInstrument (LPDIRECTMUSICPORT iface, IDirectMusicDownloadedInstrument *pDownloadedInstrument) {
More information about the wine-cvs
mailing list