summaryrefslogtreecommitdiff
path: root/lisp/image.el
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2021-12-05 19:30:27 -0800
committerPaul Eggert <eggert@cs.ucla.edu>2021-12-05 23:24:09 -0800
commit186637314dfa287b4b8178b668de92ecb57fdf1a (patch)
tree80245386924bea2cc88ac420a3e391b47a574ae4 /lisp/image.el
parent2bda02943b555b184f09dd1a5882e04a288f5026 (diff)
downloademacs-186637314dfa287b4b8178b668de92ecb57fdf1a.tar.gz
Fix image load timekeeping bug
* lisp/image.el (image-animate-timeout): Fix bug that caused the local variable time-to-load-image to be practically zero, instead of the time it actually took to load the image. I think this bug was introduced in 2013-02-16T03:29:30Z!rgm@gnu.org.
Diffstat (limited to 'lisp/image.el')
-rw-r--r--lisp/image.el6
1 files changed, 3 insertions, 3 deletions
diff --git a/lisp/image.el b/lisp/image.el
index 87fab80aad8..cedefc038f0 100644
--- a/lisp/image.el
+++ b/lisp/image.el
@@ -953,9 +953,9 @@ for the animation speed. A negative value means to animate in reverse."
(progn
(message "Stopping animation; animation possibly too big")
nil)))
- (image-show-frame image n t)
- (let* ((speed (image-animate-get-speed image))
- (time (current-time))
+ (let* ((time (prog1 (current-time)
+ (image-show-frame image n t)))
+ (speed (image-animate-get-speed image))
(time-to-load-image (time-since time))
(stated-delay-time
(/ (or (cdr (plist-get (cdr image) :animate-multi-frame-data))