GNU bug report logs -
#34196
27.0.50; tramp hangs on wrong password with global-auto-revert-mode
Previous Next
Reported by: Aaron Jensen <aaronjensen <at> gmail.com>
Date: Fri, 25 Jan 2019 15:38:01 UTC
Severity: normal
Tags: fixed
Found in version 27.0.50
Done: Michael Albinus <michael.albinus <at> gmx.de>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Aaron Jensen <aaronjensen <at> gmail.com> writes:
Hi Aaron,
> Is there any cost to an extra loop over all buffers and doing
> with-current-buffer?
There is cost, but not too much. `file-remote-p' doesn't go remote, and
it is fast:
(let ((default-directory "/sudo::"))
(benchmark 1000 (with-temp-buffer (file-remote-p default-directory))))
=> Elapsed time: 0.000060s
> I wonder if a change to auto-revert-active-p would be better than
> looping through all of the buffers and with-current-buffering them
> again. I don't know if that's semantically wrong for that function.
I've played with this idea as well. But the call is much too late for
our purposes (somewhere in the middle of auto-revert-buffers)
> Another option is putting a check in auto-revert-notify-add-watch,
> since that already has checks to ensure the file is okay to be
> watched:
>
> (or auto-revert-notify-watch-descriptor
> (and (file-remote-p default-directory)
> (not (file-remote-p default-directory nil t)))
> (string-match auto-revert-notify-exclude-dir-regexp
> (expand-file-name default-directory))
> (file-symlink-p (or buffer-file-name default-directory)))
>
> With that in place, even if I enable auto-revert-remote-files I don't
> experience the hang.
Yes, I've played with this also. auto-revert-notify-add-watch comes in
place when file notification is used. That's not the case, always.
So I tend to push my patch, if nobody complains. Let's sleep over this :-)
> Thanks,
>
> Aaron
Best regards, Michael.
This bug report was last modified 6 years and 102 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.