]> code.delx.au - gnu-emacs-elpa/commitdiff
ditch bad default-directory provision for now
authorKen Manheimer <ken.manheimer@gmail.com>
Sat, 5 Sep 2015 21:29:45 +0000 (17:29 -0400)
committerKen Manheimer <ken.manheimer@gmail.com>
Sat, 5 Sep 2015 21:29:45 +0000 (17:29 -0400)
It fails when masking other file-errors. It needs to be implemented better,
if it's still necessary.

poptoshell.el

index 7734e2b042b771c18796a6359053a5104e12a8bd..82b5f1a43c3b9f0e5f94a7600af75c619386792e 100644 (file)
@@ -132,21 +132,9 @@ Further,
           (if (not (string= (buffer-name (current-buffer))
                             target-shell-buffer-name))
               (pop-to-buffer target-shell-buffer-name t))))
-      (condition-case err
-          (if (not (comint-check-proc (current-buffer)))
-              (start-shell-in-buffer (buffer-name (current-buffer))))
-        (file-error
-         ;; Whoops - can't get to the default directory, keep trying
-         ;; superior ones till we get somewhere that's acceptable:
-         (while (and (not (string= default-directory ""))
-                     (not (condition-case err (progn (shell) t)
-                            (file-error nil))))
-           (setq default-directory
-                 (file-name-directory
-                  (substring default-directory
-                             0
-                             (1- (length default-directory)))))))
-        ))
+      (if (not (comint-check-proc (current-buffer)))
+          (start-shell-in-buffer (buffer-name (current-buffer))))
+      ))
     ;; If the destination buffer has a stopped process, resume it:
     (let ((process (get-buffer-process (current-buffer))))
       (if (and process (equal 'stop (process-status process)))