Fix when libgdiplus isn't present.

pull/408/head
Leonardo Galli 8 years ago
parent 9e7468d723
commit 336aee7fda

@ -46,11 +46,18 @@ namespace NzbDrone.Core.MediaCover
{
try
{
GdiPlusInterop.CheckGdiPlus();
using (var bmp = new Bitmap(filename))
{
}
return true;
}
catch (DllNotFoundException ex)
{
_logger.Error(ex, "Could not find libgdiplus. Cannot test if image is corrupt.");
return true;
}
catch (Exception ex)
{
_logger.Debug(ex, "Corrupted image found at: {0}. Redownloading...", filename);

Loading…
Cancel
Save