[PATCH v3 3/4] notmuch-maildir-fcc: elisp syntax fixes
authorSebastian Spaeth <Sebastian@SSpaeth.de>
Mon, 26 Apr 2010 08:23:17 +0000 (10:23 +0200)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:36:53 +0000 (09:36 -0800)
47/06287026d9512b41d420f8977af12fa2a8762b [new file with mode: 0644]

diff --git a/47/06287026d9512b41d420f8977af12fa2a8762b b/47/06287026d9512b41d420f8977af12fa2a8762b
new file mode 100644 (file)
index 0000000..e43949c
--- /dev/null
@@ -0,0 +1,87 @@
+Return-Path: <Sebastian@SSpaeth.de>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id DA32B4196F4\r
+       for <notmuch@notmuchmail.org>; Mon, 26 Apr 2010 01:23:26 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -1.9\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-1.9 tagged_above=-999 required=5\r
+       tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001] autolearn=ham\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id v-Wzq9yS71-y for <notmuch@notmuchmail.org>;\r
+       Mon, 26 Apr 2010 01:23:25 -0700 (PDT)\r
+Received: from homiemail-a15.g.dreamhost.com (mailbigip.dreamhost.com\r
+       [208.97.132.5])\r
+       by olra.theworths.org (Postfix) with ESMTP id B315A431FC1\r
+       for <notmuch@notmuchmail.org>; Mon, 26 Apr 2010 01:23:25 -0700 (PDT)\r
+Received: from localhost.localdomain (mtec-hg-docking-1-dhcp-204.ethz.ch\r
+       [129.132.133.204]) (Authenticated sender: sebastian@sspaeth.de)\r
+       by homiemail-a15.g.dreamhost.com (Postfix) with ESMTPA id 85ED276C062; \r
+       Mon, 26 Apr 2010 01:23:24 -0700 (PDT)\r
+From: Sebastian Spaeth <Sebastian@SSpaeth.de>\r
+To: Notmuch developer list <notmuch@notmuchmail.org>\r
+Subject: [PATCH v3 3/4] notmuch-maildir-fcc: elisp syntax fixes\r
+Date: Mon, 26 Apr 2010 10:23:17 +0200\r
+Message-Id: <1272270198-28357-3-git-send-email-Sebastian@SSpaeth.de>\r
+X-Mailer: git-send-email 1.7.0.4\r
+In-Reply-To: <m3bpd8tpjk.fsf@x200.gr8dns.org>\r
+References: <m3bpd8tpjk.fsf@x200.gr8dns.org>\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Mon, 26 Apr 2010 08:23:27 -0000\r
+\r
+1)use insert-buffer-substring\r
+\r
+Rather than the insert-buffer. Emacs complains that it is for interactive use\r
+and not for use within elisp. So use insert-buffer-substring which does the\r
+same thing when not handed any 'begin' 'end' parameters.\r
+\r
+2)replace caddr with (car (cdr (cdr)))\r
+\r
+The former requires 'cl to be loaded and during make install emacs complained\r
+about not knowing it.\r
+\r
+Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>\r
+---\r
+ emacs/notmuch-maildir-fcc.el |    4 ++--\r
+ 1 files changed, 2 insertions(+), 2 deletions(-)\r
+\r
+diff --git a/emacs/notmuch-maildir-fcc.el b/emacs/notmuch-maildir-fcc.el\r
+index 2117f54..84f4187 100644\r
+--- a/emacs/notmuch-maildir-fcc.el\r
++++ b/emacs/notmuch-maildir-fcc.el\r
+@@ -52,7 +52,7 @@\r
+ (defun notmuch-maildir-fcc-make-uniq-maildir-id ()\r
+    (let* ((ct (current-time))\r
+         (timeid (+ (* (car ct) 65536) (cadr ct)))\r
+-        (microseconds (caddr ct))\r
++        (microseconds (car (cdr (cdr ct))))\r
+         (hostname (notmuch-maildir-fcc-host-fixer system-name)))\r
+      (setq notmuch-maildir-fcc-count (+ notmuch-maildir-fcc-count 1))\r
+      (format "%d.%d_%d_%d.%s"\r
+@@ -97,7 +97,7 @@ non-nil, it will write it to cur/, and mark it as read. It should\r
+ return t if successful, and nil otherwise."\r
+   (let ((orig-buffer (buffer-name)))\r
+     (with-temp-buffer\r
+-      (insert-buffer orig-buffer)\r
++      (insert-buffer-substring orig-buffer)\r
+       (catch 'link-error\r
+       (let ((msg-id (notmuch-maildir-fcc-save-buffer-to-tmp destdir)))\r
+         (when msg-id\r
+-- \r
+1.7.0.4\r
+\r