aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/org
diff options
context:
space:
mode:
authorBasil L. Contovounesios2020-04-14 15:26:04 +0100
committerBasil L. Contovounesios2020-04-17 11:38:25 +0100
commit7f1dae114dffbf4bdec60e38ada4eb0673cfb4e2 (patch)
tree8a9ed4b2bf55a46e704ad68dea72736ff0b199e6 /lisp/org
parent763ec05cc17973134c440f2d0afb6eb5d095d0d4 (diff)
downloademacs-7f1dae114dffbf4bdec60e38ada4eb0673cfb4e2.tar.gz
emacs-7f1dae114dffbf4bdec60e38ada4eb0673cfb4e2.zip
Fix effect-free warning in ob-screen.el while loop
The warning was introduced and detected by an optimizer addition proposed in the following thread: https://lists.gnu.org/archive/html/emacs-devel/2019-12/msg00711.html * lisp/org/ob-screen.el (org-babel-screen-test): Avoid 'value returned from (format "...") is unused' warning by doing something more useful than busy string manipulation while waiting for an asynchronous subprocess to make the temporary file readable.
Diffstat (limited to 'lisp/org')
-rw-r--r--lisp/org/ob-screen.el2
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/org/ob-screen.el b/lisp/org/ob-screen.el
index ad00ee070d4..837c18f8407 100644
--- a/lisp/org/ob-screen.el
+++ b/lisp/org/ob-screen.el
@@ -126,7 +126,7 @@ The terminal should shortly flicker."
126 ;; XXX: need to find a better way to do the following 126 ;; XXX: need to find a better way to do the following
127 (while (not (file-readable-p tmpfile)) 127 (while (not (file-readable-p tmpfile))
128 ;; do something, otherwise this will be optimized away 128 ;; do something, otherwise this will be optimized away
129 (format "org-babel-screen: File not readable yet.")) 129 (sit-for 0.1))
130 (setq tmp-string (with-temp-buffer 130 (setq tmp-string (with-temp-buffer
131 (insert-file-contents-literally tmpfile) 131 (insert-file-contents-literally tmpfile)
132 (buffer-substring (point-min) (point-max)))) 132 (buffer-substring (point-min) (point-max))))