summaryrefslogtreecommitdiff
path: root/with-editor.el
diff options
context:
space:
mode:
Diffstat (limited to 'with-editor.el')
-rw-r--r--with-editor.el5
1 files changed, 3 insertions, 2 deletions
diff --git a/with-editor.el b/with-editor.el
index af8fc25..83b4b92 100644
--- a/with-editor.el
+++ b/with-editor.el
@@ -139,8 +139,9 @@ please see https://github.com/magit/magit/wiki/Emacsclient."))))
(with-editor-locate-emacsclient-1 path (1- depth))))))
(defun with-editor-emacsclient-version (exec)
- (ignore-errors
- (cadr (split-string (car (process-lines exec "--version"))))))
+ (let ((default-directory (file-name-directory exec)))
+ (ignore-errors
+ (cadr (split-string (car (process-lines exec "--version")))))))
(defun with-editor-emacsclient-path ()
(let ((path exec-path))