mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-12-16 04:27:16 +01:00
MediaInfo Dispose only when handle was created.
This commit is contained in:
@@ -73,12 +73,18 @@ namespace NzbDrone.Core.MediaFiles.MediaInfo
|
||||
|
||||
~MediaInfo()
|
||||
{
|
||||
MediaInfo_Delete(_handle);
|
||||
if (_handle != IntPtr.Zero)
|
||||
{
|
||||
MediaInfo_Delete(_handle);
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
MediaInfo_Delete(_handle);
|
||||
if (_handle != IntPtr.Zero)
|
||||
{
|
||||
MediaInfo_Delete(_handle);
|
||||
}
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user