Re: Hi all
[notmuch-archives.git] / a9 / 899b87405b68a8bc0d3ab6df4ad06c3364d289
1 Return-Path: <rodney@rodney.id.au>\r
2 X-Original-To: notmuch@notmuchmail.org\r
3 Delivered-To: notmuch@notmuchmail.org\r
4 Received: from localhost (localhost [127.0.0.1])\r
5         by olra.theworths.org (Postfix) with ESMTP id 53DED429E48\r
6         for <notmuch@notmuchmail.org>; Thu, 16 Feb 2012 04:38:57 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: 0.208\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0.208 tagged_above=-999 required=5\r
12         tests=[RCVD_IN_NJABL_PROXY=0.208] autolearn=disabled\r
13 Received: from olra.theworths.org ([127.0.0.1])\r
14         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
15         with ESMTP id hCvLdPqVrnCX for <notmuch@notmuchmail.org>;\r
16         Thu, 16 Feb 2012 04:38:53 -0800 (PST)\r
17 Received: from rodney.id.au (rodney.id.au [178.79.159.183])\r
18         (using TLSv1 with cipher AES256-SHA (256/256 bits))\r
19         (No client certificate requested)\r
20         by olra.theworths.org (Postfix) with ESMTPS id 890C9429E42\r
21         for <notmuch@notmuchmail.org>; Thu, 16 Feb 2012 04:38:53 -0800 (PST)\r
22 Received: from 239.16-200-80.adsl-dyn.isp.belgacom.be ([80.200.16.239]\r
23         helo=boekje.home)\r
24         by rodney.id.au with esmtpsa (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:16)\r
25         (Exim 4.77) (envelope-from <rodney@rodney.id.au>)\r
26         id 1Ry0br-0003Rz-9s; Thu, 16 Feb 2012 12:38:51 +0000\r
27 From: Rodney Lorrimar <dev@rodney.id.au>\r
28 To: Michael Hudson-Doyle <michael.hudson@canonical.com>,\r
29         notmuch@notmuchmail.org\r
30 Subject: Re: notmuch-emacs bug report -- infinite looping trying to select\r
31         next message\r
32 In-Reply-To: <87ty2tjcx5.fsf@canonical.com>\r
33 References: <877gzql7e3.fsf@canonical.com> <87zkcllpkv.fsf@boekje.home>\r
34         <87ty2tjcx5.fsf@canonical.com>\r
35 User-Agent: Notmuch/0.11.1 (http://notmuchmail.org) Emacs/24.0.93.1\r
36         (x86_64-pc-linux-gnu)\r
37 Date: Thu, 16 Feb 2012 13:39:01 +0100\r
38 Message-ID: <87ipj7kl5m.fsf@boekje.home>\r
39 MIME-Version: 1.0\r
40 Content-Type: text/plain\r
41 X-SA-Exim-Connect-IP: 80.200.16.239\r
42 X-SA-Exim-Mail-From: rodney@rodney.id.au\r
43 X-SA-Exim-Scanned: No (on rodney.id.au); SAEximRunCond expanded to false\r
44 X-BeenThere: notmuch@notmuchmail.org\r
45 X-Mailman-Version: 2.1.13\r
46 Precedence: list\r
47 List-Id: "Use and development of the notmuch mail system."\r
48         <notmuch.notmuchmail.org>\r
49 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
50         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
51 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
52 List-Post: <mailto:notmuch@notmuchmail.org>\r
53 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
54 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
55         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
56 X-List-Received-Date: Thu, 16 Feb 2012 12:38:57 -0000\r
57 \r
58 Hi Michael,\r
59 \r
60 On Wed, 15 Feb 2012 10:57:42 +1300, Michael Hudson-Doyle <michael.hudson@canonical.com> wrote:\r
61 > Thanks for the reply!\r
62\r
63 > On Tue, 14 Feb 2012 10:41:20 +0100, Rodney Lorrimar <dev@rodney.id.au> wrote:\r
64 > > Hi Michael,\r
65 > > \r
66 > > On Tue, 14 Feb 2012 11:01:56 +1300, Michael Hudson-Doyle <michael.hudson@canonical.com> wrote:\r
67 > > > The attached gzipped mbox appears to trip up the emacs interface.  The\r
68 > > > problem seems to come from the message with id\r
69 > > > CAGNsrLCWv6=36q+q+5Hc_SzgdZ2ergeKkapT7T3xXvim=2cK+A@mail.gmail.com.\r
70 > > > \r
71 > > > If you load up the thread in emacs, you get a message:\r
72 > > > \r
73 > > > mm-extern-cache-contents: Couldn't find access type\r
74 > > \r
75 > > If you put (require 'gnus-art) into your .emacs and eval it, does the\r
76 > > problem go away?\r
77\r
78 > No.\r
79 \r
80 Oh well.\r
81 \r
82 I loaded up the thread in notmuch and also got an infinite loop.\r
83 \r
84 > > > Then attempting to advance past the last display message (or pressing A,\r
85 > > > or a few other things I expect gets emacs to loop indefinitely.\r
86 > > > toggle-debug-on-quit gets me this backtrace:\r
87 > > \r
88 > > I believe the actual bug is in gnus but I don't really like the loop on\r
89 > > error behaviour of notmuch. I would like to try and fix it but haven't\r
90 > > found the time.\r
91\r
92 > As far as I can tell, gnus isn't involved here.  I may be wrong, of\r
93 > course!\r
94 \r
95 After setting a breakpoint in mm-extern-cache-contents I'm inclined to\r
96 agree, but I'm not really sure.\r
97 \r
98 The following hack to 0.11 works around the problem. I think the experts\r
99 here would be able to come up with something better.\r
100 \r
101 Cheers,\r
102 \r
103 Rodney\r
104 \r
105 diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el\r
106 index 82d11c9..48c15d2 100644\r
107 --- a/emacs/notmuch-show.el\r
108 +++ b/emacs/notmuch-show.el\r
109 @@ -327,7 +327,8 @@ current buffer, if possible."\r
110      (with-temp-buffer\r
111        (let ((handle (mm-make-handle (current-buffer) (list content-type))))\r
112     (if (and (mm-inlinable-p handle)\r
113 -        (mm-inlined-p handle))\r
114 +        (mm-inlined-p handle)\r
115 +        (cdr (mm-handle-type handle)))\r
116         (let ((content (notmuch-show-get-bodypart-content msg part nth)))\r
117           (insert content)\r
118           (set-buffer display-buffer)\r