unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#25445: Bug (Trunk): Redirect fails in Duckduckgo
@ 2017-01-14  5:34 Ian Dunn
  2017-01-14  7:13 ` npostavs
  0 siblings, 1 reply; 9+ messages in thread
From: Ian Dunn @ 2017-01-14  5:34 UTC (permalink / raw)
  To: 25445

[-- Attachment #1: Type: text/plain, Size: 225 bytes --]


    Due I believe to a change in Duckduckgo's API, eww is no longer able to work with Duckduckgo.  It appears that they are using a referrer tag with single quotes rather than double quotes.  The attached patch fixes this.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: eww.el.diff --]
[-- Type: text/x-diff, Size: 633 bytes --]

diff --git a/lisp/net/eww.el b/lisp/net/eww.el
index d42180719d..b051c1ac85 100644
--- a/lisp/net/eww.el
+++ b/lisp/net/eww.el
@@ -501,6 +501,7 @@ Currently this means either text/html or application/xhtml+xml."
              (< eww-redirect-level 5))
     (when-let (refresh (dom-attr dom 'content))
       (when (or (string-match "^\\([0-9]+\\) *;.*url=\"\\([^\"]+\\)\"" refresh)
+                (string-match "^\\([0-9]+\\) *;.*url='\\([^ ]+\\)'" refresh)
                 (string-match "^\\([0-9]+\\) *;.*url=\\([^ ]+\\)" refresh))
         (let ((timeout (match-string 1 refresh))
               (url (match-string 2 refresh))

[-- Attachment #3: Type: text/plain, Size: 13 bytes --]


--
Ian Dunn

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2017-01-16 19:24 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-14  5:34 bug#25445: Bug (Trunk): Redirect fails in Duckduckgo Ian Dunn
2017-01-14  7:13 ` npostavs
2017-01-14 14:34   ` Ian Dunn
2017-01-16  0:35     ` npostavs
2017-01-16  3:33       ` Eli Zaretskii
2017-01-16  4:27         ` npostavs
2017-01-16 18:12       ` Achim Gratz
2017-01-16 18:24         ` Noam Postavsky
2017-01-16 19:24           ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).