mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
* lisp/url/url-cache.el (url-fetch-from-cache): New function.
This commit is contained in:
parent
2bc0110432
commit
50e4f0bf34
2 changed files with 10 additions and 0 deletions
|
|
@ -68,6 +68,12 @@ FILE can be created or overwritten."
|
|||
(let ((coding-system-for-write 'binary))
|
||||
(write-region (point-min) (point-max) fname nil 5))))))
|
||||
|
||||
(defun url-fetch-from-cache (url)
|
||||
"Fetch URL from cache and return a buffer with the content."
|
||||
(with-current-buffer (generate-new-buffer " *temp*")
|
||||
(url-cache-extract (url-cache-create-filename url))
|
||||
(current-buffer)))
|
||||
|
||||
;;;###autoload
|
||||
(defun url-is-cached (url)
|
||||
"Return non-nil if the URL is cached."
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue