]> git.eshelyaron.com Git - emacs.git/commitdiff
Adapt last change to non-NS systems
authorPo Lu <luangruo@yahoo.com>
Wed, 24 Jul 2024 03:59:53 +0000 (11:59 +0800)
committerEshel Yaron <me@eshelyaron.com>
Wed, 24 Jul 2024 16:57:58 +0000 (18:57 +0200)
* src/image.c (xpm_load_image): Also check whether mask_img is
NULL.

(cherry picked from commit 3a76354e092f291037367b65b24c1963fd0fe31f)

src/image.c

index 70ec1b316ee09a9fb0f403b147736b40b89f0558..9d97337fd31e5ca370d8d0bd200b0b3699bc94b6 100644 (file)
@@ -6505,7 +6505,8 @@ xpm_load_image (struct frame *f,
   if (ximg)
     {
       image_destroy_x_image (ximg);
-      image_destroy_x_image (mask_img);
+      if (mask_img)
+       image_destroy_x_image (mask_img);
       image_clear_image (f, img);
     }
   return 0;