DOCUMENT:Q242918 08-MAY-2002 [win95x] TITLE :DCOM Heap Memory Leak When Using IDataObject/IAdviseSink PRODUCT :Microsoft Windows 95.x Retail Product PROD/VER:WINDOWS:; Win2000:95 OPER/SYS: KEYWORDS:win95 win98 win98se ====================================================================== ------------------------------------------------------------------------------- The information in this article applies to: - Microsoft Windows 95 - Microsoft Windows 98 - Microsoft Windows 98 Second Edition ------------------------------------------------------------------------------- SYMPTOMS ======== When you use Uniform Data Transfer calls to IAdviseSink::OnDataChange, a memory leak of 32 bytes on the client side and 148 bytes on the server side may occur. The problem occurs only when the client uses the STA model. RESOLUTION ========== A supported fix is now available from Microsoft, but it is only intended to correct the problem described in this article and should be applied only to systems experiencing this specific problem. This fix may receive additional testing at a later time, to further ensure product quality. Therefore, if you are not severely affected by this problem, Microsoft recommends that you wait for the next DCOM release that contains this fix. To resolve this problem immediately, contact Microsoft Product Support Services to obtain the fix. For a complete list of Microsoft Product Support Services phone numbers and information about support costs, please go to the following address on the World Wide Web: http://support.microsoft.com/default.aspx?scid=fh;EN-US;CNTACTMS NOTE: In special cases, charges that are normally incurred for support calls may be canceled, if a Microsoft Support Professional determines that a specific update will resolve your problem. Normal support costs will apply to additional support questions and issues that do not qualify for the specific update in question. The English-language version of this fix should have the following file attributes or later: Date Time Version Size File name Platform ----------------------------------------------------------------- 12/17/99 09:33PM 4.71.1015.0 1,229,056 Dcom95.exe Windows 95 12/16/99 09:22PM 4.71.1015.0 1,229,056 Dcom98.exe Windows 98 SE STATUS ====== Microsoft has confirmed this to be a problem in the Microsoft products that are listed at the beginning of this article. MORE INFORMATION ================ There is a memory link in OLE32 when you use Uniform Data Transfer between a data object on a local server that implements the IDataObject interface and a client that implements the IAdviseSink interface. When a client wants to be notified by a data object server that data has been modified, it calls IDataObject::DAdvise, giving the server a pointer to the client's IAdviseSink interface. When the data is modified on the server, the server calls IAdviseSink::OnDataChange to notify the client. The client calls IDataObject::DUnAdvise to break the connection. OLE implements data advise holder which implements IDataAdviseHolder (created by CreateDataAdviseHolder) to help the data object to notify all clients that are connected to the data object. The server calls IDataAdviseHolder::SendOnDataChange and the data advise holder then calls IAdviseSink::OnDataChange on each advise sink that is connected to the server. The problem is that every call to IAdviseSink::OnDataChange causes a memory leak of one object of 32 bytes on the client side and 148 bytes on the server side. The problem only occurs when the client uses the STA model. Additional query words: ====================================================================== Keywords : win95 win98 win98se Technology : kbWin95search kbWin98search kbWin98SEsearch kbZNotKeyword3 kbWin98 kbWin98SE Version : WINDOWS:; Win2000:95 Hardware : ALPHA x86 Issue type : kbbug Solution Type : kbfix ============================================================================= THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY. Copyright Microsoft Corporation 2002.