CoUnmarshalInterface and firewalls
One of the features I have recently worked on is improving our error messages around firewalls. I have a suggestion to anyone trying to use CoUnmarshalInterface to unmarshal an interface on a remote machine – don’t show the user the HRESULT returned from this API. The return code is typically useless (E_OUTOFMEMORY is common). Instead, just say something like:
The Visual Studio debugger cannot connect to the remote computer. Unable to initiate DCOM communication.