From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tassilo Horn Subject: Re: [bug] org-store-link on gnus message fails Date: Wed, 12 Jan 2011 17:45:17 +0100 Message-ID: <87bp3moyua.fsf@member.fsf.org> References: <87wrmaz0ip.fsf@ucl.ac.uk> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from [140.186.70.92] (port=42736 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pd3pM-00028y-NY for emacs-orgmode@gnu.org; Wed, 12 Jan 2011 11:45:41 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pd3pL-00038h-HN for emacs-orgmode@gnu.org; Wed, 12 Jan 2011 11:45:40 -0500 Received: from lo.gmane.org ([80.91.229.12]:50656) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pd3pL-00038L-9Z for emacs-orgmode@gnu.org; Wed, 12 Jan 2011 11:45:39 -0500 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Pd3pH-00023y-HU for emacs-orgmode@gnu.org; Wed, 12 Jan 2011 17:45:35 +0100 Received: from tsdh.uni-koblenz.de ([141.26.67.142]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 12 Jan 2011 17:45:35 +0100 Received: from tassilo by tsdh.uni-koblenz.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 12 Jan 2011 17:45:35 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hi Eric, this patch should do the trick. I think the issue was a malformed Date: header that couldn't be converted to a timestamp. --8<---------------cut here---------------start------------->8--- diff --git a/lisp/org-gnus.el b/lisp/org-gnus.el index 32641bf..ae5dc52 100644 --- a/lisp/org-gnus.el +++ b/lisp/org-gnus.el @@ -152,11 +152,16 @@ If `org-store-link' was called with a prefix arg the meaning of (from (mail-header-from header)) (message-id (org-remove-angle-brackets (mail-header-id header))) (date (org-trim (mail-header-date header))) - (date-ts (and date (format-time-string - (org-time-stamp-format t) (date-to-time date)))) - (date-ts-ia (and date (format-time-string - (org-time-stamp-format t t) - (date-to-time date)))) + (date-ts (and date + (condition-case nil + (format-time-string + (org-time-stamp-format t) + (date-to-time date))))) + (date-ts-ia (and date + (condition-case nil + (format-time-string + (org-time-stamp-format t t) + (date-to-time date))))) (subject (copy-sequence (mail-header-subject header))) (to (cdr (assq 'To (mail-header-extra header)))) newsgroups x-no-archive desc link) --8<---------------cut here---------------end--------------->8--- Bye, Tassilo