GNU bug report logs -
#79186
31.0.50; Make dynamic binding of url-max-redirections work
Previous Next
Full log
Message #10 received at 79186 <at> debbugs.gnu.org (full text, mbox):
>>>>> On Wed, 06 Aug 2025 22:28:18 +0200, "Peder O. Klingenberg" <peder <at> klingenberg.no> said:
Peder> Following on from bug#61916, there was one variable I missed that should
Peder> also have a faux-dynamic binding: url-max-redirections.
Peder> To demonstrate:
Peder> (setq url-debug t) ;; and follow the results in the *URL-DEBUG* buffer
Peder> (setq url-max-redirections 30) ;; the default
Peder> (let ((url-max-redirections 0))
Peder> (url-retrieve "http://httpbin.org/redirect/5"
Peder> #'(lambda (&rest _args)
Peder> (message "done"))))
Peder> This will cause 5 redirections to be followed by url-http.el, because it
Peder> still sees url-max-redirections as 30.
Peder> With the attached patch it stops after the first redirection.
I tried to apply this, but it failed because you quoted `like this`,
which our commit hooks reject. Best is to quote 'like this' in commit
messages and resubmit (this also gives you the chance to add
(Bug#79186) somewhere in the commit message 😀).
Robert
--
This bug report was last modified 2 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.