diff -up mate-desktop/libmate-desktop/mate-desktop-thumbnail.c~ mate-desktop/libmate-desktop/mate-desktop-thumbnail.c --- mate-desktop/libmate-desktop/mate-desktop-thumbnail.c~ 2022-09-27 16:53:40.943355497 +0200 +++ mate-desktop/libmate-desktop/mate-desktop-thumbnail.c 2022-09-27 16:53:40.960355614 +0200 @@ -150,6 +150,21 @@ thumbnailer_load (Thumbnailer *thumb) thumb->try_exec = g_key_file_get_string (key_file, THUMBNAILER_ENTRY_GROUP, "TryExec", NULL); + if (thumb->try_exec != NULL) + { + gchar *path_to_exec = g_find_program_in_path (thumb->try_exec); + + if (path_to_exec == NULL) + { + g_message ("Ignoring thumbnailer with missing binary: '%s'", thumb->try_exec); + thumbnailer_unref (thumb); + g_key_file_free (key_file); + return NULL; + } + + g_free (path_to_exec); + } + g_key_file_free (key_file); return thumb;