Subject: bug#36403: 27.0.50; Trivial image.c bugs

From: Lars Ingebrigtsen <[email-masked]>
Date: Fri, 21 Aug 2020 01:13:58 +0200

Alan Third <[email-masked]> writes:

> Hi, this patch appears to have broken something (in NS at least) and
> now interactively resizing an image no longer causes the image to be
> immediately redisplayed. I have to force a redisplay some other way
> before I see the resized image.

Yup.  This patch fixes things for me (on Debian)...

diff --git a/src/image.c b/src/image.c
index 643b3d0a1f..ceb690ed0a 100644
--- a/src/image.c
+++ b/src/image.c
@@ -1633,7 +1633,7 @@ search_image_cache (struct frame *f, Lisp_Object spec, EMACS_UINT hash)
 
   for (img = c->buckets[i]; img; img = img->next)
     if (img->hash == hash
-	&& !equal_lists (img->spec, spec)
+	&& !NILP (Fequal (img->spec, spec))
 	&& img->frame_foreground == FRAME_FOREGROUND_PIXEL (f)
 	&& img->frame_background == FRAME_BACKGROUND_PIXEL (f))
       break;

The equal_lists thing looks sensible, but I guess we do destructive
alterations with +/-, possibly, to equal is the correct thing, not a
list-of-eqs?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no