Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
50e4f0bf
Commit
50e4f0bf
authored
Sep 19, 2010
by
Julien Danjou
Committed by
Glenn Morris
Sep 19, 2010
Browse files
* lisp/url/url-cache.el (url-fetch-from-cache): New function.
parent
2bc01104
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
0 deletions
+10
-0
lisp/url/ChangeLog
lisp/url/ChangeLog
+4
-0
lisp/url/url-cache.el
lisp/url/url-cache.el
+6
-0
No files found.
lisp/url/ChangeLog
View file @
50e4f0bf
2010-09-19 Julien Danjou <julien@danjou.info>
* url-cache.el (url-fetch-from-cache): New function.
2010-09-18 Julien Danjou <julien@danjou.info>
* url-vars.el (url-cache-expired): Remove unused variable.
...
...
lisp/url/url-cache.el
View file @
50e4f0bf
...
...
@@ -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."
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment