D
Dmitry Akselrod
Hello everyone,
I am working in Visual Studio 2002 (I wonder if that's part of the problem).
The reason I am working in 2002 is to keep everything compatible with .NET
Framework 1.0. I wrote a small COM DLL in unmanaged C++. I am using the
DLL in a managed VB.NET application. The DLL basically just reads the
properties of compound structured storage files. The DLL uses ATL for some
String functions. The VB.NET application uses the information passed by the
COM DLL to communicate with an MS Access database.
The VB.NET program works just fine for a few hours, indexing the properties
of tons of structured storage files. After a few hours, it craps out with
the following error messages:
System.OutOfMemoryException: Creating an instance of the COM component with
CLSID {375D546A-4313-4CD4-9E3C-F71095F100F8} from the IClassFactory failed
due to the following error: 8007000e.
I checked the DLL and I don't believe that anything is being left on the
heap. Every NEW has an associated DELETE call. I believe that COM objects
associated with structured storage are being properly released, since the
files I am indexing do not remain locked. I noticed that if you don't
release a COM pointer or one doesn't go out of scope, Windows keeps the
structured storage file locked.
I am not entirely sure how I can troubleshoot this, especially since it
takes hours for the issue to occur. Is this likely a memory leak? Could
this be an issue with Visual Studio 2002? Is it on the .NET framework side
or on the unmanaged C++ side (ATL). If I compile the DLL is VS2005, but
still use VS2002 for the .NET app, would that make a difference? I am
really stuck here and would appreciate some advice on how to proceed.
Thanks in advance!
I am working in Visual Studio 2002 (I wonder if that's part of the problem).
The reason I am working in 2002 is to keep everything compatible with .NET
Framework 1.0. I wrote a small COM DLL in unmanaged C++. I am using the
DLL in a managed VB.NET application. The DLL basically just reads the
properties of compound structured storage files. The DLL uses ATL for some
String functions. The VB.NET application uses the information passed by the
COM DLL to communicate with an MS Access database.
The VB.NET program works just fine for a few hours, indexing the properties
of tons of structured storage files. After a few hours, it craps out with
the following error messages:
System.OutOfMemoryException: Creating an instance of the COM component with
CLSID {375D546A-4313-4CD4-9E3C-F71095F100F8} from the IClassFactory failed
due to the following error: 8007000e.
I checked the DLL and I don't believe that anything is being left on the
heap. Every NEW has an associated DELETE call. I believe that COM objects
associated with structured storage are being properly released, since the
files I am indexing do not remain locked. I noticed that if you don't
release a COM pointer or one doesn't go out of scope, Windows keeps the
structured storage file locked.
I am not entirely sure how I can troubleshoot this, especially since it
takes hours for the issue to occur. Is this likely a memory leak? Could
this be an issue with Visual Studio 2002? Is it on the .NET framework side
or on the unmanaged C++ side (ATL). If I compile the DLL is VS2005, but
still use VS2002 for the .NET app, would that make a difference? I am
really stuck here and would appreciate some advice on how to proceed.
Thanks in advance!