From: Ian Dunn <dunni@gnu.org>
To: 27333@debbugs.gnu.org
Subject: bug#27333: URL History can't handle records
Date: Sun, 11 Jun 2017 16:01:18 -0400 [thread overview]
Message-ID: <87wp8iway9.fsf@escafil> (raw)
[-- Attachment #1: Type: text/plain, Size: 576 bytes --]
Since the change to records a few months ago, I've seen a bug with `url-history-save-history'. When I try to run it, I see:
Error running timer ‘url-history-save-history’: (wrong-type-argument stringp #s(url "https" nil nil "duckduckgo.com" nil "/html/?q=emacs" nil nil t nil t))
A backtrace puts it at the `string-match' call in `url-history-save-history'. I think the problem is that url-history is using a url struct instead of a string, which, according to `url-history-update-url', isn't supposed to be happening.
The following patch should fix this:
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/x-diff, Size: 544 bytes --]
diff --git a/lisp/url/url-history.el b/lisp/url/url-history.el
index 1fa085400d..af52d5861e 100644
--- a/lisp/url/url-history.el
+++ b/lisp/url/url-history.el
@@ -106,7 +106,7 @@ to run the `url-history-setup-save-timer' function manually."
(defun url-history-update-url (url time)
(setq url-history-changed-since-last-save t)
- (puthash (if (vectorp url) (url-recreate-url url) url) time
+ (puthash (if (recordp url) (url-recreate-url url) url) time
url-history-hash-table))
(autoload 'url-make-private-file "url-util")
[-- Attachment #3: Type: text/plain, Size: 14 bytes --]
--
Ian Dunn
next reply other threads:[~2017-06-11 20:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-11 20:01 Ian Dunn [this message]
2017-06-28 11:42 ` bug#27333: URL History can't handle records npostavs
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87wp8iway9.fsf@escafil \
--to=dunni@gnu.org \
--cc=27333@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).