{"thread":{"id":"11527","subject":"[PATCH 1/3] git.el: Make sure we never insert the same file twice.","startedAt":"2008-01-08T13:45:46Z","lastAt":"2008-01-08T13:45:46Z","messageCount":1,"participants":["Alexandre Julliard"],"isPatch":true,"patchVersion":1,"patchTotal":3},"messages":[{"id":"64737","messageId":"873at8jur9.fsf@wine.dyndns.org","threadId":"11527","inReplyTo":null,"subject":"[PATCH 1/3] git.el: Make sure we never insert the same file twice.","fromName":"Alexandre Julliard","fromEmail":"julliard@winehq.org","sentAt":"2008-01-08T13:45:46Z","receivedAt":"2008-01-08T13:45:46Z","isPatch":true,"sender":{"key":"julliard@winehq.org","avatar":null},"body":"Skip non-zero stage files during git-ls-files -c, they are handled\nlater. Also fix git-insert-info-list to merge duplicate file names.\n\nSigned-off-by: Alexandre Julliard <julliard@winehq.org>\n---\n contrib/emacs/git.el |    6 +++---\n 1 files changed, 3 insertions(+), 3 deletions(-)\n\ndiff --git a/contrib/emacs/git.el b/contrib/emacs/git.el\nindex 9a0f03f..885ad20 100644\n--- a/contrib/emacs/git.el\n+++ b/contrib/emacs/git.el\n@@ -608,7 +608,7 @@ and returns the process output as a string.\"\n     (while info\n       (setf (git-fileinfo->needs-refresh info) t)\n       (cond ((not node)\n-             (ewoc-enter-last status info)\n+             (setq node (ewoc-enter-last status info))\n              (setq info (pop infolist)))\n             ((string-lessp (git-fileinfo->name (ewoc-data node))\n                            (git-fileinfo->name info))\n@@ -620,7 +620,7 @@ and returns the process output as a string.\"\n               (setf (ewoc-data node) info)\n               (setq info (pop infolist)))\n             (t\n-             (ewoc-enter-before status node info)\n+             (setq node (ewoc-enter-before status node info))\n              (setq info (pop infolist)))))))\n \n (defun git-run-diff-index (status files)\n@@ -677,7 +677,7 @@ Return the list of files that haven't been handled.\"\n     (with-temp-buffer\n       (apply #'git-call-process-env t nil \"ls-files\" \"-z\" \"-s\" \"-c\" \"--\" files)\n       (goto-char (point-min))\n-      (while (re-search-forward \"\\\\([0-7]\\\\{6\\\\}\\\\) [0-9a-f]\\\\{40\\\\} [0-3]\\t\\\\([^\\0]+\\\\)\\0\" nil t)\n+      (while (re-search-forward \"\\\\([0-7]\\\\{6\\\\}\\\\) [0-9a-f]\\\\{40\\\\} 0\\t\\\\([^\\0]+\\\\)\\0\" nil t)\n \t(let* ((new-perm (string-to-number (match-string 1) 8))\n \t       (old-perm (if (eq default-state 'added) 0 new-perm))\n \t       (name (match-string 2)))\n-- \n1.5.4.rc2.71.ge10a9\n\n-- \nAlexandre Julliard\njulliard@winehq.org\n"}]}