dsound: Trace ref in a consistent way.
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com> Signed-off-by: Andrew Eikum <aeikum@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
2d6de2d129
commit
061121b81a
|
@ -60,7 +60,7 @@ static ULONG WINAPI IDirectSoundNotifyImpl_AddRef(IDirectSoundNotify *iface)
|
|||
IDirectSoundBufferImpl *This = impl_from_IDirectSoundNotify(iface);
|
||||
ULONG ref = InterlockedIncrement(&This->refn);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if(ref == 1)
|
||||
InterlockedIncrement(&This->numIfaces);
|
||||
|
@ -73,7 +73,7 @@ static ULONG WINAPI IDirectSoundNotifyImpl_Release(IDirectSoundNotify *iface)
|
|||
IDirectSoundBufferImpl *This = impl_from_IDirectSoundNotify(iface);
|
||||
ULONG ref = InterlockedDecrement(&This->refn);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if (!ref && !InterlockedDecrement(&This->numIfaces))
|
||||
secondarybuffer_destroy(This);
|
||||
|
@ -344,7 +344,7 @@ static ULONG WINAPI IDirectSoundBufferImpl_AddRef(IDirectSoundBuffer8 *iface)
|
|||
IDirectSoundBufferImpl *This = impl_from_IDirectSoundBuffer8(iface);
|
||||
ULONG ref = InterlockedIncrement(&This->ref);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if(ref == 1)
|
||||
InterlockedIncrement(&This->numIfaces);
|
||||
|
@ -361,7 +361,7 @@ static ULONG WINAPI IDirectSoundBufferImpl_Release(IDirectSoundBuffer8 *iface)
|
|||
ref = capped_refcount_dec(&This->ref);
|
||||
if(!ref)
|
||||
capped_refcount_dec(&This->numIfaces);
|
||||
TRACE("(%p) ref is now: %d\n", This, ref);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -369,7 +369,7 @@ static ULONG WINAPI IDirectSoundBufferImpl_Release(IDirectSoundBuffer8 *iface)
|
|||
if (!ref && !InterlockedDecrement(&This->numIfaces))
|
||||
secondarybuffer_destroy(This);
|
||||
|
||||
TRACE("(%p) ref is now %d\n", This, ref);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
return ref;
|
||||
}
|
||||
|
@ -1237,7 +1237,7 @@ static ULONG WINAPI IKsPropertySetImpl_AddRef(IKsPropertySet *iface)
|
|||
IDirectSoundBufferImpl *This = impl_from_IKsPropertySet(iface);
|
||||
ULONG ref = InterlockedIncrement(&This->refiks);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if(ref == 1)
|
||||
InterlockedIncrement(&This->numIfaces);
|
||||
|
@ -1254,7 +1254,7 @@ static ULONG WINAPI IKsPropertySetImpl_Release(IKsPropertySet *iface)
|
|||
ref = capped_refcount_dec(&This->refiks);
|
||||
if(!ref)
|
||||
capped_refcount_dec(&This->numIfaces);
|
||||
TRACE("(%p) ref is now: %d\n", This, ref);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -1262,7 +1262,7 @@ static ULONG WINAPI IKsPropertySetImpl_Release(IKsPropertySet *iface)
|
|||
if (!ref && !InterlockedDecrement(&This->numIfaces))
|
||||
secondarybuffer_destroy(This);
|
||||
|
||||
TRACE("(%p) ref is now %d\n", This, ref);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
return ref;
|
||||
}
|
||||
|
|
|
@ -137,7 +137,7 @@ static ULONG WINAPI IDirectSoundNotifyImpl_AddRef(IDirectSoundNotify *iface)
|
|||
IDirectSoundCaptureBufferImpl *This = impl_from_IDirectSoundNotify(iface);
|
||||
ULONG ref = InterlockedIncrement(&This->refn);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if(ref == 1)
|
||||
InterlockedIncrement(&This->numIfaces);
|
||||
|
@ -150,7 +150,7 @@ static ULONG WINAPI IDirectSoundNotifyImpl_Release(IDirectSoundNotify *iface)
|
|||
IDirectSoundCaptureBufferImpl *This = impl_from_IDirectSoundNotify(iface);
|
||||
ULONG ref = InterlockedDecrement(&This->refn);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if (!ref && !InterlockedDecrement(&This->numIfaces))
|
||||
capturebuffer_destroy(This);
|
||||
|
@ -263,7 +263,7 @@ static ULONG WINAPI IDirectSoundCaptureBufferImpl_AddRef(IDirectSoundCaptureBuff
|
|||
IDirectSoundCaptureBufferImpl *This = impl_from_IDirectSoundCaptureBuffer8(iface);
|
||||
ULONG ref = InterlockedIncrement(&This->ref);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if(ref == 1)
|
||||
InterlockedIncrement(&This->numIfaces);
|
||||
|
@ -276,7 +276,7 @@ static ULONG WINAPI IDirectSoundCaptureBufferImpl_Release(IDirectSoundCaptureBuf
|
|||
IDirectSoundCaptureBufferImpl *This = impl_from_IDirectSoundCaptureBuffer8(iface);
|
||||
ULONG ref = InterlockedDecrement(&This->ref);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if (!ref && !InterlockedDecrement(&This->numIfaces))
|
||||
capturebuffer_destroy(This);
|
||||
|
@ -851,7 +851,7 @@ static ULONG DirectSoundCaptureDevice_Release(
|
|||
DirectSoundCaptureDevice * device)
|
||||
{
|
||||
ULONG ref = InterlockedDecrement(&(device->ref));
|
||||
TRACE("(%p) ref was %d\n", device, ref + 1);
|
||||
TRACE("(%p) ref %d\n", device, ref);
|
||||
|
||||
if (!ref) {
|
||||
TRACE("deleting object\n");
|
||||
|
|
|
@ -189,7 +189,7 @@ static HRESULT DirectSoundDevice_Create(DirectSoundDevice ** ppDevice)
|
|||
static ULONG DirectSoundDevice_AddRef(DirectSoundDevice * device)
|
||||
{
|
||||
ULONG ref = InterlockedIncrement(&(device->ref));
|
||||
TRACE("(%p) ref was %d\n", device, ref - 1);
|
||||
TRACE("(%p) ref %d\n", device, ref);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -197,7 +197,7 @@ static ULONG DirectSoundDevice_Release(DirectSoundDevice * device)
|
|||
{
|
||||
HRESULT hr;
|
||||
ULONG ref = InterlockedDecrement(&(device->ref));
|
||||
TRACE("(%p) ref was %u\n", device, ref + 1);
|
||||
TRACE("(%p) ref %d\n", device, ref);
|
||||
if (!ref) {
|
||||
int i;
|
||||
|
||||
|
|
|
@ -675,7 +675,7 @@ static ULONG WINAPI PrimaryBufferImpl_AddRef(IDirectSoundBuffer8 *iface)
|
|||
{
|
||||
IDirectSoundBufferImpl *This = impl_from_IDirectSoundBuffer8(iface);
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
if(ref == 1)
|
||||
InterlockedIncrement(&This->numIfaces);
|
||||
return ref;
|
||||
|
@ -704,7 +704,7 @@ static ULONG WINAPI PrimaryBufferImpl_Release(IDirectSoundBuffer8 *iface)
|
|||
if(!ref)
|
||||
capped_refcount_dec(&This->numIfaces);
|
||||
|
||||
TRACE("(%p) primary ref is now %d\n", This, ref);
|
||||
TRACE("(%p) primary ref %d\n", This, ref);
|
||||
|
||||
return ref;
|
||||
}
|
||||
|
|
|
@ -81,7 +81,7 @@ static ULONG WINAPI IKsPrivatePropertySetImpl_AddRef(LPKSPROPERTYSET iface)
|
|||
{
|
||||
IKsPrivatePropertySetImpl *This = impl_from_IKsPropertySet(iface);
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -89,7 +89,7 @@ static ULONG WINAPI IKsPrivatePropertySetImpl_Release(LPKSPROPERTYSET iface)
|
|||
{
|
||||
IKsPrivatePropertySetImpl *This = impl_from_IKsPropertySet(iface);
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if (!ref) {
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
|
|
@ -396,7 +396,7 @@ static ULONG WINAPI IDirectSound3DBufferImpl_AddRef(IDirectSound3DBuffer *iface)
|
|||
IDirectSoundBufferImpl *This = impl_from_IDirectSound3DBuffer(iface);
|
||||
ULONG ref = InterlockedIncrement(&This->ref3D);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if(ref == 1)
|
||||
InterlockedIncrement(&This->numIfaces);
|
||||
|
@ -409,7 +409,7 @@ static ULONG WINAPI IDirectSound3DBufferImpl_Release(IDirectSound3DBuffer *iface
|
|||
IDirectSoundBufferImpl *This = impl_from_IDirectSound3DBuffer(iface);
|
||||
ULONG ref = InterlockedDecrement(&This->ref3D);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if (!ref && !InterlockedDecrement(&This->numIfaces))
|
||||
secondarybuffer_destroy(This);
|
||||
|
@ -744,7 +744,7 @@ static ULONG WINAPI IDirectSound3DListenerImpl_AddRef(IDirectSound3DListener *if
|
|||
IDirectSoundBufferImpl *This = impl_from_IDirectSound3DListener(iface);
|
||||
ULONG ref = InterlockedIncrement(&This->ref3D);
|
||||
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
if(ref == 1)
|
||||
InterlockedIncrement(&This->numIfaces);
|
||||
|
@ -761,7 +761,7 @@ static ULONG WINAPI IDirectSound3DListenerImpl_Release(IDirectSound3DListener *i
|
|||
if(!ref)
|
||||
capped_refcount_dec(&This->numIfaces);
|
||||
|
||||
TRACE("(%p) ref is now %d\n", This, ref);
|
||||
TRACE("(%p) ref %d\n", This, ref);
|
||||
|
||||
return ref;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue