diff options
| author | Richard M. Stallman | 2002-12-21 20:20:47 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 2002-12-21 20:20:47 +0000 |
| commit | 44a9ca8b7ef609ce41685ae6049c734928c9ea83 (patch) | |
| tree | 9cd1d20e51e09c4bfe55f76985b5c1c61cb0c8c3 | |
| parent | 3fa9a7dfd743eef596ac9d8dba0ddbdfbd7f4971 (diff) | |
| download | emacs-44a9ca8b7ef609ce41685ae6049c734928c9ea83.tar.gz emacs-44a9ca8b7ef609ce41685ae6049c734928c9ea83.zip | |
(original-insert-directory): Make this a variable,
don't set its function definition.
(insert-directory): Use funcall to call that function.
| -rw-r--r-- | lisp/ls-lisp.el | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lisp/ls-lisp.el b/lisp/ls-lisp.el index 3bf7d55f4c1..9f6de6753c6 100644 --- a/lisp/ls-lisp.el +++ b/lisp/ls-lisp.el | |||
| @@ -162,9 +162,12 @@ current year. The OLD-TIME-FORMAT is used for older files. To use ISO | |||
| 162 | (string :tag "Old time format")) | 162 | (string :tag "Old time format")) |
| 163 | :group 'ls-lisp) | 163 | :group 'ls-lisp) |
| 164 | 164 | ||
| 165 | (defvar original-insert-directory nil | ||
| 166 | "This holds the original function definition of `insert-directory'.") | ||
| 167 | |||
| 165 | ;; Remember the original insert-directory function | 168 | ;; Remember the original insert-directory function |
| 166 | (or (featurep 'ls-lisp) ; FJW: unless this file is being reloaded! | 169 | (or (featurep 'ls-lisp) ; FJW: unless this file is being reloaded! |
| 167 | (fset 'original-insert-directory (symbol-function 'insert-directory))) | 170 | (setq original-insert-directory (symbol-function 'insert-directory))) |
| 168 | 171 | ||
| 169 | ;; This stub is to allow ls-lisp to parse symbolic links via another | 172 | ;; This stub is to allow ls-lisp to parse symbolic links via another |
| 170 | ;; library such as w32-symlinks.el from | 173 | ;; library such as w32-symlinks.el from |
| @@ -200,7 +203,8 @@ is non-nil; otherwise, it interprets wildcards as regular expressions | |||
| 200 | to match file names. It does not support all `ls' switches -- those | 203 | to match file names. It does not support all `ls' switches -- those |
| 201 | that work are: A a c i r S s t u U X g G B C R and F partly." | 204 | that work are: A a c i r S s t u U X g G B C R and F partly." |
| 202 | (if ls-lisp-use-insert-directory-program | 205 | (if ls-lisp-use-insert-directory-program |
| 203 | (original-insert-directory file switches wildcard full-directory-p) | 206 | (funcall original-insert-directory |
| 207 | file switches wildcard full-directory-p) | ||
| 204 | ;; We need the directory in order to find the right handler. | 208 | ;; We need the directory in order to find the right handler. |
| 205 | (let ((handler (find-file-name-handler (expand-file-name file) | 209 | (let ((handler (find-file-name-handler (expand-file-name file) |
| 206 | 'insert-directory))) | 210 | 'insert-directory))) |