]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix hang in autorevert-tests.el
authorMichael Albinus <michael.albinus@gmx.de>
Sun, 28 Mar 2021 19:06:24 +0000 (21:06 +0200)
committerMichael Albinus <michael.albinus@gmx.de>
Sun, 28 Mar 2021 19:06:24 +0000 (21:06 +0200)
* test/lisp/autorevert-tests.el (auto-revert--wait-for-revert):
Apply more robust check, whether file notification is used.

test/lisp/autorevert-tests.el

index 6ced9a1ac8feca3e7e7df36e2319e41079034321..8b8313df0150b7d3ce96c0684325c899a71906fd 100644 (file)
@@ -131,7 +131,9 @@ This expects `auto-revert--messages' to be bound by
                        (format-message
                         "Reverting buffer `%s'\\." (buffer-name buffer))
                        auto-revert--messages)))
-      (if (with-current-buffer buffer auto-revert-use-notify)
+      (if (and (or file-notify--library
+                   (file-remote-p temporary-file-directory))
+               (with-current-buffer buffer auto-revert-use-notify))
           (read-event nil nil 0.1)
         (sleep-for 0.1)))))