Commit 2a438aa0 authored by Robert Reif's avatar Robert Reif Committed by Alexandre Julliard

Keep dsound8.c and dsound.c in sync.

parent 7bfc2902
...@@ -98,7 +98,7 @@ static void IDirectSound_test(LPDIRECTSOUND dso, BOOL initialized, ...@@ -98,7 +98,7 @@ static void IDirectSound_test(LPDIRECTSOUND dso, BOOL initialized,
trace(" No Device\n"); trace(" No Device\n");
return; return;
} else if (rc==DSERR_ALLOCATED) { } else if (rc==DSERR_ALLOCATED) {
trace(" Already Allocated\n"); trace(" Already In Use\n");
return; return;
} }
} }
......
...@@ -104,18 +104,16 @@ static void IDirectSound8_test(LPDIRECTSOUND8 dso, BOOL initialized, ...@@ -104,18 +104,16 @@ static void IDirectSound8_test(LPDIRECTSOUND8 dso, BOOL initialized,
DXGetErrorString8(rc)); DXGetErrorString8(rc));
rc=IDirectSound8_Initialize(dso,lpGuid); rc=IDirectSound8_Initialize(dso,lpGuid);
ok(rc==DS_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED, ok(rc==DS_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED||rc==E_FAIL,
"IDirectSound8_Initialize() failed: %s\n",DXGetErrorString8(rc)); "IDirectSound8_Initialize() failed: %s\n",DXGetErrorString8(rc));
if (rc==DSERR_NODRIVER) { if (rc==DSERR_NODRIVER) {
trace(" No Driver\n"); trace(" No Driver\n");
return; return;
} } else if (rc==E_FAIL) {
if (rc==DSERR_ALLOCATED) { trace(" No Device\n");
trace(" Already In Use\n");
return; return;
} } else if (rc==DSERR_ALLOCATED) {
if (rc==E_FAIL) { trace(" Already In Use\n");
trace(" Could not initialize DirectSound.\n");
return; return;
} }
} }
...@@ -233,21 +231,21 @@ static void IDirectSound8_tests() ...@@ -233,21 +231,21 @@ static void IDirectSound8_tests()
/* try with no device specified */ /* try with no device specified */
rc=pDirectSoundCreate8(NULL,&dso,NULL); rc=pDirectSoundCreate8(NULL,&dso,NULL);
ok(rc==S_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED, ok(rc==S_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED||rc==E_FAIL,
"DirectSoundCreate8() failed: %s\n",DXGetErrorString8(rc)); "DirectSoundCreate8() failed: %s\n",DXGetErrorString8(rc));
if (rc==DS_OK && dso) if (rc==DS_OK && dso)
IDirectSound8_test(dso, TRUE, NULL); IDirectSound8_test(dso, TRUE, NULL);
/* try with default playback device specified */ /* try with default playback device specified */
rc=pDirectSoundCreate8(&DSDEVID_DefaultPlayback,&dso,NULL); rc=pDirectSoundCreate8(&DSDEVID_DefaultPlayback,&dso,NULL);
ok(rc==S_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED, ok(rc==S_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED||rc==E_FAIL,
"DirectSoundCreate8() failed: %s\n",DXGetErrorString8(rc)); "DirectSoundCreate8() failed: %s\n",DXGetErrorString8(rc));
if (rc==DS_OK && dso) if (rc==DS_OK && dso)
IDirectSound8_test(dso, TRUE, NULL); IDirectSound8_test(dso, TRUE, NULL);
/* try with default voice playback device specified */ /* try with default voice playback device specified */
rc=pDirectSoundCreate8(&DSDEVID_DefaultVoicePlayback,&dso,NULL); rc=pDirectSoundCreate8(&DSDEVID_DefaultVoicePlayback,&dso,NULL);
ok(rc==S_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED, ok(rc==S_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED||rc==E_FAIL,
"DirectSoundCreate8() failed: %s\n",DXGetErrorString8(rc)); "DirectSoundCreate8() failed: %s\n",DXGetErrorString8(rc));
if (rc==DS_OK && dso) if (rc==DS_OK && dso)
IDirectSound8_test(dso, TRUE, NULL); IDirectSound8_test(dso, TRUE, NULL);
...@@ -271,7 +269,7 @@ static HRESULT test_dsound8(LPGUID lpGuid) ...@@ -271,7 +269,7 @@ static HRESULT test_dsound8(LPGUID lpGuid)
/* Create the DirectSound8 object */ /* Create the DirectSound8 object */
rc=pDirectSoundCreate8(lpGuid,&dso,NULL); rc=pDirectSoundCreate8(lpGuid,&dso,NULL);
ok(rc==DS_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED, ok(rc==DS_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED||rc==E_FAIL,
"DirectSoundCreate8() failed: %s\n",DXGetErrorString8(rc)); "DirectSoundCreate8() failed: %s\n",DXGetErrorString8(rc));
if (rc!=DS_OK) if (rc!=DS_OK)
return rc; return rc;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment