From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Ian Dunn Newsgroups: gmane.emacs.bugs Subject: bug#27333: URL History can't handle records Date: Sun, 11 Jun 2017 16:01:18 -0400 Message-ID: <87wp8iway9.fsf@escafil> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: blaine.gmane.org 1497211391 25362 195.159.176.226 (11 Jun 2017 20:03:11 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 11 Jun 2017 20:03:11 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) To: 27333@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Jun 11 22:03:07 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dK94k-0006Lu-Uj for geb-bug-gnu-emacs@m.gmane.org; Sun, 11 Jun 2017 22:03:07 +0200 Original-Received: from localhost ([::1]:35037 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dK94q-0007u1-8n for geb-bug-gnu-emacs@m.gmane.org; Sun, 11 Jun 2017 16:03:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:38916) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dK94h-0007tg-5M for bug-gnu-emacs@gnu.org; Sun, 11 Jun 2017 16:03:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dK94g-0007WQ-9w for bug-gnu-emacs@gnu.org; Sun, 11 Jun 2017 16:03:03 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:38749) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dK94g-0007WI-6B for bug-gnu-emacs@gnu.org; Sun, 11 Jun 2017 16:03:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dK94f-00082R-QL for bug-gnu-emacs@gnu.org; Sun, 11 Jun 2017 16:03:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Ian Dunn Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 11 Jun 2017 20:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 27333 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.149721137130879 (code B ref -1); Sun, 11 Jun 2017 20:03:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 11 Jun 2017 20:02:51 +0000 Original-Received: from localhost ([127.0.0.1]:41426 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dK94V-00081z-5S for submit@debbugs.gnu.org; Sun, 11 Jun 2017 16:02:51 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:47886) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dK94T-00081m-0P for submit@debbugs.gnu.org; Sun, 11 Jun 2017 16:02:49 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dK94N-0007Oy-20 for submit@debbugs.gnu.org; Sun, 11 Jun 2017 16:02:43 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:37173) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dK94M-0007Ou-Uo for submit@debbugs.gnu.org; Sun, 11 Jun 2017 16:02:42 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:38857) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dK94L-0007tE-S0 for bug-gnu-emacs@gnu.org; Sun, 11 Jun 2017 16:02:42 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dK94L-0007Oc-2J for bug-gnu-emacs@gnu.org; Sun, 11 Jun 2017 16:02:41 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:60965) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dK94K-0007OY-Uy for bug-gnu-emacs@gnu.org; Sun, 11 Jun 2017 16:02:40 -0400 Original-Received: from [2604:6000:1010:176:da4d:3352:bae5:f50e] (port=49958 helo=escafil) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1dK94K-0000I9-EZ for bug-gnu-emacs@gnu.org; Sun, 11 Jun 2017 16:02:40 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:133479 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Since the change to records a few months ago, I've seen a bug with `url-his= tory-save-history'. When I try to run it, I see: Error running timer =E2=80=98url-history-save-history=E2=80=99: (wrong-type= -argument stringp #s(url "https" nil nil "duckduckgo.com" nil "/html/?q=3De= macs" 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 o= f a string, which, according to `url-history-update-url', isn't supposed to= be happening. The following patch should fix this: --=-=-= Content-Type: text/x-diff Content-Disposition: inline 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") --=-=-= Content-Type: text/plain -- Ian Dunn --=-=-=--