Copy the OXID_INFO from the stub manager, if available, in
proxy_manager_construct. Otherwise, attempt to resolve it.
Use ipidRemUnknown from OXID_INFO in the proxy manager instead of
magically generating the IPID for RemUnknown.
so that the right external reference count is released when the proxy is destroyed.
Protect all changes to refs in the ifproxy using interlocked functions
and update the thread-safety documentation.
Otherwise we would leak a reference for both of these if the ifstub was already created.
Fix the FIXME in the code by releasing the stub manager if necessary.
reference on the stub object so that the first proxy can be released.
Implement external refcount sharing between a proxy and the marshaled proxy.
Extend the marshaling of a proxy test to show that an external reference
is always kept on the stub object.
Release the proxy buffer object on the last release of the proxy's outer
unknown, otherwise memory is leaked for the Ndr implementation of
IRpcProxyBuffer.
Fix up the hand-coded proxies to match the behaviour from the Ndr
implementation.
Change stub manager to track the number of normal marshals instead of
using the state machine so that multiple marshals of the same object
and interface work correctly.
to proxies, causing potential deadlock issues and performance
problems.
- Add a test for this situation and remove the todo_wine from another
test that now succeeds.
pointing to the completely wrong object when a proxy does a
queryinterface.
- Remove assumption that the stub buffer will handle the lifetime of
the object.
- Fix more places where custom header size was calculated exclusive of
the data size member.
- Optimize custom marshaling by getting size before calling the custom
marshaler so we can write the header before and not use a second
stream.
- Move the modal loop called during RPCs into CoWaitForMultipleHandles.
- Use a mutex for long remoting calls to IRemUnknown methods.
- Remove locking in apartment_disconnectproxies as it is not needed.
- Use PostMessage instead of SendMessage so we can run the message
loop or not as appropriate.
- Rename register_ifstub to marshal_object to more accurately describe
what it does.
- Add new function, apartment_getoxid, to prepare for a possible
future patch where remoting is started on demand.
the apartment structure.
- Don't pass an IPID by value for proxy_manager_create_ifproxy.
- Disable more of RPC_UnregisterInterface to prevent the RPC runtime
using freed memory.
- Rename various external RPC backend functions so that they all have
the same "RPC_" prefix.
- Reduce the timeout of the function that connects to a local server
to 30s, like native.
- Rework RPC dispatch layer to be simpler and not get confused by
server/client duality.
- Make threads shut down at the right time and not access freed memory
after apartment destruction.
- Rename stub_dispatch_thread to client_dispatch_thread.
- Add some more tracing
- Check return value of WaitNamedPipe.
- Change named pipe timeouts to 0.5s, which should be enough for even the slowest machines.