]> git.eshelyaron.com Git - emacs.git/commitdiff
(custom-load-symbol): Simplify previous change.
authorRichard M. Stallman <rms@gnu.org>
Sat, 31 May 1997 02:47:47 +0000 (02:47 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sat, 31 May 1997 02:47:47 +0000 (02:47 +0000)
lisp/cus-edit.el

index 25843805497f296f17267d3b30912185de645984..e15a39a015c4829d84a1d1155e117810caabda2b 100644 (file)
@@ -1306,10 +1306,15 @@ Change the state of this item."
               (condition-case nil
                   (require load)
                 (error nil)))
-             ((assoc load load-history))
+             ;; Don't reload a file already loaded.
+             ((assoc (locate-library load) load-history))
              (t
               (condition-case nil
-                  (load-library load)
+                  ;; Without this, we would load cus-edit recursively.
+                  ;; We are still loading it when we call this,
+                  ;; and it is not in load-history yet.
+                  (or (equal load "cus-edit")
+                      (load-library load))
                 (error nil))))))))
 
 (defun custom-load-widget (widget)