On 2010-08-14 19:31 +0100, Leo wrote: > Something is broken. > > If you add two stashes and try to view the second one, it throws an > error.
The bug was introduced in the following commit: [1efde9202ce712495ed7010fac1c172be90d8b94] Filter out HEAD refs from magit-name-rev. I have fixed it in my local branch with the following patch. commit 4d01bd00a0f5eeb2ae072cfaeb5a240b7e3db7f7 Author: Leo <[email protected]> Date: Sun Aug 15 17:16:16 2010 +0100 Fix a bug introduced in 1efde92 Modified magit.el diff --git a/magit.el b/magit.el index f51a2aa..36fe74a 100644 --- a/magit.el +++ b/magit.el @@ -536,7 +536,8 @@ out revs involving HEAD." ;; There doesn't seem to be a way of filtering HEAD out from name-rev, ;; so we have to do it manually. ;; HEAD-based names are too transient to allow. - (when (string-match "^\\(.*\\<HEAD\\)\\([~^].*\\|$\\)" name) + (when (and (stringp name) + (string-match "^\\(.*\\<HEAD\\)\\([~^].*\\|$\\)" name)) (let ((head-ref (match-string 1 name)) (modifier (match-string 2 name))) ;; Sometimes when name-rev gives a HEAD-based name, Cheers, Leo
