![](/img/trans.png)
[英]Returning an OleVariant from a function causes an extra reference on the contained IDispatch object that cannot be released
我有一個 function,它返回一個OleVariant ,其中包含一個IDispatch引用,計數為 object: 在 function 的末尾,OleVariant 中OleVariant的RefCount正確為1 。 但是當OleVariant返回給調用者時,包含的 object 突然有一 ...