BUG: Class Terminate Event May Not Fire When You Use a UDT That Contains a Dynamic Array (320106)
The information in this article applies to:
- Microsoft Visual Studio, Professional Edition 6.0
- Microsoft Visual Studio 6.0 SP1
- Microsoft Visual Studio 6.0 SP2
- Microsoft Visual Studio 6.0 SP3
- Microsoft Visual Studio 6.0 SP4
- Microsoft Visual Studio, Enterprise Edition 6.0
This article was previously published under Q320106 SYMPTOMS
If a class has a public user-defined type (UDT) that contains a dynamic array as a property, the Terminate event of the class may fail to fire when the client accesses the dynamic array directly through the public UDT property. This may lead to memory leak.
RESOLUTION
To work around this problem, use one of the following methods:
- Do not select Optimize for Fast Code when you compile the client project.
- Replace the string array inside the UDT with a Variant.
- Do not access the string array elements directly from the UDT that is returned.
For more information about how to implement these workarounds, refer to the "More Information" section.
STATUSMicrosoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article.
Modification Type: | Minor | Last Reviewed: | 8/15/2005 |
---|
Keywords: | kbbug kbnofix KB320106 |
---|
|