emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: auto-revert error on macOS when auto-revert-use-notify is t


From: zhang cc
Subject: Re: auto-revert error on macOS when auto-revert-use-notify is t
Date: Sun, 11 Mar 2018 04:26:21 +0000

Yes. this seems OK. But there is a delay before auto-revert every 2 appending to the test file.


echo aaa >> test.c   (auto-revert ok)

echo aaa >> test.c   (delay about 4s, then auto-revert ok)

echo aaa >> test.c   (auto-revert ok)

echo aaa >> test.c   (delay about 4s, then auto-revert ok)


I added some debug log to two method (name in []):

[file-notify-callback]: (9 (extend write) /Users/jun/test/1.c)

[auto-revert-notify-handler]: (9 changed /Users/jun/test/1.c)

Reverting buffer 1.c.

[file-notify-callback]: (9 (extend write) /Users/jun/test/1.c)

[auto-revert-notify-handler]: (9 changed /Users/jun/test/1.c)

[file-notify-callback]: (9 (extend write) /Users/jun/test/1.c)

[auto-revert-notify-handler]: (9 changed /Users/jun/test/1.c)

[file-notify-callback]: (9 (extend write) /Users/jun/test/1.c)

[auto-revert-notify-handler]: (9 changed /Users/jun/test/1.c)

Reverting buffer 1.c.


3 write events but only one auto-revert.


There is a big delay before auto-reverting, not every one, about every two or three.
You can modify the test file with the following bash script:

#!/bin/bash

for (( i = 0; i < 100; i++ ));
do
        echo $i >> 1.c
        sleep 2
done



reply via email to

[Prev in Thread] Current Thread [Next in Thread]