diff --git a/Flow.Launcher.Infrastructure/Image/ThumbnailReader.cs b/Flow.Launcher.Infrastructure/Image/ThumbnailReader.cs index c942488c4..9f38a64df 100644 --- a/Flow.Launcher.Infrastructure/Image/ThumbnailReader.cs +++ b/Flow.Launcher.Infrastructure/Image/ThumbnailReader.cs @@ -141,7 +141,15 @@ namespace Flow.Launcher.Infrastructure.Image } catch { - hBitmap = GetHBitmap(Path.GetFullPath(fileName), width, height, options); + try + { + hBitmap = GetHBitmap(Path.GetFullPath(fileName), width, height, options); + } + catch (System.Exception ex) + { + // Handle other exceptions + throw new InvalidOperationException("Failed to get thumbnail", ex); + } } return hBitmap;