diff options
-rw-r--r-- | lisp/net/eww.el | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lisp/net/eww.el b/lisp/net/eww.el index 4df9740d540..6559c7e5eb9 100644 --- a/lisp/net/eww.el +++ b/lisp/net/eww.el @@ -651,9 +651,10 @@ Will call each function in `eww-guess-content-type-functions', until one of them returns a value. This mechanism is used only if there isn't a valid Content-Type header. If none of the functions can guess, return \"application/octet-stream\"." - (or (run-hook-with-args-until-success - 'eww-guess-content-type-functions headers response-buffer) - "application/octet-stream")) + (save-excursion + (or (run-hook-with-args-until-success + 'eww-guess-content-type-functions headers response-buffer) + "application/octet-stream"))) (defun eww--html-if-doctype (_headers response-buffer) "Return \"text/html\" if RESPONSE-BUFFER has an HTML doctype declaration. |