Commit 6bfae1a1 authored by Robert Shearman's avatar Robert Shearman Committed by Alexandre Julliard

- IRpcStubBuffer_Disconnect can be called multiple times.

- Release TypeLib when freeing stub buffer.
parent 775898ba
...@@ -1974,6 +1974,7 @@ TMStubImpl_Release(LPRPCSTUBBUFFER iface) ...@@ -1974,6 +1974,7 @@ TMStubImpl_Release(LPRPCSTUBBUFFER iface)
if (!refCount) if (!refCount)
{ {
IRpcStubBuffer_Disconnect(iface); IRpcStubBuffer_Disconnect(iface);
ITypeInfo_Release(This->tinfo);
CoTaskMemFree(This); CoTaskMemFree(This);
} }
return refCount; return refCount;
...@@ -1998,9 +1999,11 @@ TMStubImpl_Disconnect(LPRPCSTUBBUFFER iface) ...@@ -1998,9 +1999,11 @@ TMStubImpl_Disconnect(LPRPCSTUBBUFFER iface)
TRACE("(%p)->()\n", This); TRACE("(%p)->()\n", This);
IUnknown_Release(This->pUnk); if (This->pUnk)
This->pUnk = NULL; {
return; IUnknown_Release(This->pUnk);
This->pUnk = NULL;
}
} }
static HRESULT WINAPI static HRESULT WINAPI
......
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