From mboxrd@z Thu Jan 1 00:00:00 1970 From: Lawrence Mitchell Subject: [PATCH 2/2] lisp/ob.el: Don't modify babel info when hashing it Date: Thu, 2 Jun 2011 11:04:05 +0100 Message-ID: <1307009045-10010-2-git-send-email-wence@gmx.li> References: <1307009045-10010-1-git-send-email-wence@gmx.li> Return-path: Received: from eggs.gnu.org ([140.186.70.92]:53611) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QS59M-0002GI-MF for emacs-orgmode@gnu.org; Thu, 02 Jun 2011 06:29:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QS59K-00019u-UW for emacs-orgmode@gnu.org; Thu, 02 Jun 2011 06:29:12 -0400 Received: from garnet.epcc.ed.ac.uk ([129.215.56.222]:57429) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QS59K-000169-Dq for emacs-orgmode@gnu.org; Thu, 02 Jun 2011 06:29:10 -0400 In-Reply-To: <1307009045-10010-1-git-send-email-wence@gmx.li> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Cc: Lawrence Mitchell * lisp/ob.el (org-babel-sha1-hash): Don't modify info argument by side-effect when sorting result-params list. copy-sequence only does shallow copies, so if we're going to modify a sub-list, we need to make sure we copy it first. --- lisp/ob.el | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/lisp/ob.el b/lisp/ob.el index e1f4372..36649f0 100644 --- a/lisp/ob.el +++ b/lisp/ob.el @@ -767,7 +767,7 @@ the current subtree." (cond ((and (listp v) ; lists are sorted (member (car arg) '(:result-params))) - (sort v #'string<)) + (sort (copy-sequence v) #'string<)) ((and (stringp v) ; strings are sorted (member (car arg) '(:results :exports))) (mapconcat #'identity (sort (split-string v) -- 1.7.4.1