BUG: DCOM95 MTA Clients May Block Broadcast DDE MessagesLast reviewed: March 2, 1998Article ID: Q181949 |
The information in this article applies to:
SYMPTOMSDue to a bug in the RPC runtime DLLs that ship with DCOM951.1, MTA clients that do not service the message queue may block the global broadcast of DDE messages. When a user double-clicks on a desktop icon, the program associated with the icon may be blocked from launching and Windows Explorer may hang.
CAUSEA top-level window is created by the RPC runtime on the MTA client thread that called CoCreateInstance(Ex), but the window is not destroyed when the API returns. The client thread has no obligation to service the message queue under the MTA programming model. If it does not, this top-level window causes global DDE broadcast messages to block.
RESOLUTIONTo work around this bug, you need to make the client's MTA thread behave like an STA thread (that is, it must service the message queue). If it is blocking on a win32 handle, it must call the MsgWaitForMultipleObjects() API to simultaneously dispatch windows messages. See the REFERENCES section for an article that explains how to do this.
STATUSMicrosoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. We are researching this bug and will post new information here in the Microsoft Knowledge Base as it becomes available.
MORE INFORMATIONA thread initializes COM libraries for the Single Threaded Apartment(STA) by calling CoInitializeEx(0, COINIT_APARTMENTTHREADED), or simply CoInitialize() or OleInitialize(). This type of thread must service the message queue for the following two reasons:
REFERENCESFor additional information, please see the following article in the Microsoft Knowledge Base:
ARTICLE-ID: Q136885 TITLE : INFO: OLE Threads Must Dispatch Messages Keywords : LeTwoCom Issue type : kbbug |
================================================================================
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |