bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#38774: crash in image_pix_context_get_pixel


From: mituharu
Subject: bug#38774: crash in image_pix_context_get_pixel
Date: Sun, 29 Dec 2019 21:52:19 +0900
User-agent: SquirrelMail/1.4.22-5.el6

>
> Recent emacs configured with
>
> configure -C --without-all --with-xml2 --with-dbus --with-m17n-flt
>  --with-libotf --with-xft --with-x-toolkit=athena
>  --with-toolkit-scroll-bars --with-xaw3d --with-cairo --with-harfbuzz
>  --with-png
>
> crashes on startup

Could you try the patch below?

                                     YAMAMOTO Mitsuharu
                                mituharu@math.s.chiba-u.ac.jp

diff --git a/src/image.c b/src/image.c
index fc90c5ea74..7172bfc810 100644
--- a/src/image.c
+++ b/src/image.c
@@ -1242,6 +1242,10 @@ prepare_image_for_display (struct frame *f, struct
image *img)
       if (img->cr_data == NULL || (cairo_pattern_get_type (img->cr_data)
                                   != CAIRO_PATTERN_TYPE_SURFACE))
        {
+         /* Fill in the background/background_transparent field while
+            we have img->pixmap->data/img->mask->data.  */
+         IMAGE_BACKGROUND (img, f, img->pixmap);
+         IMAGE_BACKGROUND_TRANSPARENT (img, f, img->mask);
          cr_put_image_to_cr_data (img);
          if (img->cr_data == NULL)
            {







reply via email to

[Prev in Thread] Current Thread [Next in Thread]