emacs-pretest-bug
[Top][All Lists]
Advanced

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

Re: recentf-cleanup, file-readable-p & remote files


From: Jesper Harder
Subject: Re: recentf-cleanup, file-readable-p & remote files
Date: Wed, 17 Sep 2003 04:10:49 +0200
User-agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3.50 (gnu/linux)

David PONCE <address@hidden> writes:

> IMO a better solution would be to allow to disable connection
> timeout when calling the `file-readable-p' remote handler (I don't
> know if this is feasible).  So when not connected, `file-readable-p'
> will immediately return nil, without waiting for a remote
> connection.

Ah, I think you misunderstood part of what I was trying to say --
which is that `file-readable-p' can be very slow when you *are*
connected (when I'm not connected it returns in a fraction of second,
so that's not a problem)

The reason is that that ange-ftp implements it rather inefficiently.
Instead of just listing the file in question it lists *all* files in
the directory.  That's a lot of data if the directory contains
thousands of files.  In the example from my previous post doing
`file-readable-p' is ~500 times slower than actually fetching the
file!

-- 
Cheers,
Jesper Harder





reply via email to

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