emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

scratch/package-vc-fixes 6080b169f3 47/48: Avoid duplicate source packag


From: Philip Kaludercic
Subject: scratch/package-vc-fixes 6080b169f3 47/48: Avoid duplicate source packages in 'package-alist'
Date: Wed, 16 Nov 2022 04:50:11 -0500 (EST)

branch: scratch/package-vc-fixes
commit 6080b169f3fcff240c5b48420e4a8948dae43ac4
Author: Philip Kaludercic <philipk@posteo.net>
Commit: Philip Kaludercic <philipk@posteo.net>

    Avoid duplicate source packages in 'package-alist'
    
    * lisp/emacs-lisp/package-vc.el (package-vc--unpack-1): Remove all
    other source packages before installing the new package description.
---
 lisp/emacs-lisp/package-vc.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/emacs-lisp/package-vc.el b/lisp/emacs-lisp/package-vc.el
index b201c9d150..bf5865adb6 100644
--- a/lisp/emacs-lisp/package-vc.el
+++ b/lisp/emacs-lisp/package-vc.el
@@ -391,7 +391,7 @@ documentation and marking the package as installed."
   ;; Remove any previous instance of PKG-DESC from `package-alist'
   (let ((pkgs (assq (package-desc-name pkg-desc) package-alist)))
     (when pkgs
-      (setf (cdr pkgs) (delq pkg-desc (cdr pkgs)))))
+      (setf (cdr pkgs) (seq-remove #'package-vc-p (cdr pkgs)))))
 
   ;; In case the package was installed directly from source, the
   ;; dependency list wasn't know beforehand, and they might have



reply via email to

[Prev in Thread] Current Thread [Next in Thread]