[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#526: Emacs 22, url package, problems with cache
From: |
Julien Danjou |
Subject: |
bug#526: Emacs 22, url package, problems with cache |
Date: |
Fri, 22 Jul 2011 16:04:01 +0200 |
User-agent: |
Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.50 (gnu/linux) |
On Thu, Jul 03 2008, Alexander Pohoyda wrote:
> The url-automatic-caching variable is nil by default, so cache is not
> written (even the cache directory is not created). However, if I manually
> provide "If-Modified-Since" header in HTTP request and the server responds
> with "Not Modified 304", the cache file is expected to exists and is
> accessed -- which leads to error.
>
> Possible solution -- before accessing the cache file, check whether it exists
> (url-is-cached).
> Alternatively, do not expect a cache to exist if url-automatic-caching is set
> to nil.
I'm not sure this is really a bug after all. If you send a
"If-Modified-Since" header, you have to already own a copy of the
content. If what you propose is to return an empty buffer if there's no
cache, that does not seems like the good solution neither. And I would
not see the point to re-request the URL without the IMS header neither.
304 code is only returned if the client has done a conditional request,
which should be the case *only* if it has a cached copy. Otherwise it's
no sense.
--
Julien Danjou
❱ http://julien.danjou.info
pgprW1ulcKTrc.pgp
Description: PGP signature
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- bug#526: Emacs 22, url package, problems with cache,
Julien Danjou <=