[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 7b67b9a5a2: Store less data in the gif animation cache
From: |
Lars Ingebrigtsen |
Subject: |
master 7b67b9a5a2: Store less data in the gif animation cache |
Date: |
Tue, 12 Apr 2022 08:45:35 -0400 (EDT) |
branch: master
commit 7b67b9a5a2135d479dfe86f40109778ac5f99920
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>
Store less data in the gif animation cache
* src/image.c (gif_load): Only start a cache if we're have an
:index entry (which means that we're trying to animate something).
---
src/image.c | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/src/image.c b/src/image.c
index f56d02bf19..b6edcf96a0 100644
--- a/src/image.c
+++ b/src/image.c
@@ -8814,14 +8814,12 @@ gif_load (struct frame *f, struct image *img)
EMACS_INT idx = -1;
int gif_err;
struct anim_cache* cache = NULL;
-
/* Which sub-image are we to display? */
- {
- Lisp_Object image_number = image_spec_value (img->spec, QCindex, NULL);
- idx = FIXNUMP (image_number) ? XFIXNAT (image_number) : 0;
- }
+ Lisp_Object image_number = image_spec_value (img->spec, QCindex, NULL);
+
+ idx = FIXNUMP (image_number) ? XFIXNAT (image_number) : 0;
- if (idx != -1)
+ if (!NILP (image_number))
{
/* If this is an animated image, create a cache for it. */
cache = anim_get_animation_cache (img->spec);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master 7b67b9a5a2: Store less data in the gif animation cache,
Lars Ingebrigtsen <=