Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed "COM object that has been separated from its underlying RCW can…

…not be used." in MetaDataImport
  • Loading branch information...
commit fb51065400a17286a8936fdd8527c96526afe229 1 parent 4116a1a
@dsrbecky dsrbecky authored
View
16 src/AddIns/Debugger/Debugger.Core/Interop/MetaDataWrapper.cs
@@ -16,7 +16,7 @@ namespace Debugger.Interop.MetaData
{
/// <summary>Wrapper for the unmanaged metadata API.</summary>
/// <remarks>http://msdn.microsoft.com/en-us/library/ms230172.aspx</remarks>
- public class MetaDataImport: IDisposable
+ public class MetaDataImport
{
const int DefaultBufferSize = 8;
// If buffer is too small, enlarge it
@@ -53,20 +53,6 @@ public ISymUnmanagedReader GetSymReader(IStream stream)
}
}
- ~MetaDataImport()
- {
- Dispose();
- }
-
- public void Dispose()
- {
- IMetaDataImport m = this.metaData;
- if (m != null) {
- Marshal.FinalReleaseComObject(m);
- metaData = null;
- }
- }
-
// CloseEnum, CountEnum and ResetEnum are not wrapped, use them directly
// GetNameFromToken is obsolete
View
2  src/AddIns/Debugger/Debugger.Core/Module.cs
@@ -307,8 +307,6 @@ public void ApplyChanges(byte[] metadata, byte[] il)
public void Dispose()
{
UnloadSymbols();
- metaData.Dispose();
-
unloaded = true;
}
Please sign in to comment.
Something went wrong with that request. Please try again.