+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):
(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, ...;