Commit 97b3a214 authored by Lars Hansen's avatar Lars Hansen
Browse files

(desktop-load-file): Do nothing when FUNCTION is nil.

parent cc9e7d91
2005-10-12 Lars Hansen <larsh@soem.dk>
* desktop.el (desktop-load-file): Do nothing when FUNCTION is nil.
Reported by Reiner Steib <Reiner.Steib@gmx.de>.
2005-10-11 Sven Joachim <svenjoac@gmx.de>
* progmodes/sh-script.el (sh-tmp-file):
......
......@@ -963,10 +963,11 @@ directory DIRNAME."
(defun desktop-load-file (function)
"Load the file where auto loaded FUNCTION is defined."
(let ((fcell (symbol-function function)))
(when (and (listp fcell)
(eq 'autoload (car fcell)))
(load (cadr fcell)))))
(when function
(let ((fcell (symbol-function function)))
(when (and (listp fcell)
(eq 'autoload (car fcell)))
(load (cadr fcell))))))
;; ----------------------------------------------------------------------------
;; Create a buffer, load its file, set its mode, ...;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment