diff options
author | Richard M. Stallman <rms@gnu.org> | 1995-08-22 20:27:05 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1995-08-22 20:27:05 +0000 |
commit | 81da0333f3e9ebd678a31e2fcf26b99eb8526b54 (patch) | |
tree | b158b12788f38ec9e8426440f0686301a47acc83 /lisp/ediff-util.el | |
parent | ddb9945d7c2926331595e2efd805ca2ebfcc2f9e (diff) | |
download | emacs-81da0333f3e9ebd678a31e2fcf26b99eb8526b54.tar.gz |
(ediff-profile): Use make-local-hook and add and remove hooks locally.
Diffstat (limited to 'lisp/ediff-util.el')
-rw-r--r-- | lisp/ediff-util.el | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/lisp/ediff-util.el b/lisp/ediff-util.el index d12d19f1f02..8c8f4dc2c1f 100644 --- a/lisp/ediff-util.el +++ b/lisp/ediff-util.el @@ -3035,15 +3035,15 @@ avoid loading cl-*." (interactive) (or (ediff-buffer-live-p ediff-control-buffer) (error "This command runs only out of Ediff Control Buffer")) - (make-local-variable 'pre-command-hook) - (make-local-variable 'post-command-hook) + (make-local-hook 'pre-command-hook) + (make-local-hook 'post-command-hook) (if (memq 'ediff-save-time pre-command-hook) - (progn (remove-hook 'pre-command-hook 'ediff-save-time) - (remove-hook 'post-command-hook 'ediff-calc-command-time) + (progn (remove-hook 'pre-command-hook 'ediff-save-time t) + (remove-hook 'post-command-hook 'ediff-calc-command-time t) (setq ediff-command-begin-time '(0 0 0)) (message "Ediff profiling disabled")) - (add-hook 'pre-command-hook 'ediff-save-time t) - (add-hook 'post-command-hook 'ediff-calc-command-time) + (add-hook 'pre-command-hook 'ediff-save-time t t) + (add-hook 'post-command-hook 'ediff-calc-command-time nil t) (message "Ediff profiling enabled"))) (defun ediff-print-diff-vector (diff-vector-var) |