--- a/lisp/tar-mode.el
+++ b/lisp/tar-mode.el
@@ -531,6 +542,7 @@ defun tar-untar-buffer ()
   (interactive)
   ;; FIXME: make it work even if we're not in tar-mode.
-  (let ((descriptors tar-parse-info))   ;Read the var in its buffer.
+  (let ((descriptors tar-parse-info)    ; Read the var in its buffer.
+        (dest-dir default-directory))
     (with-current-buffer
         (if (tar-data-swapped-p) tar-data-buffer (current-buffer))
       (set-buffer-multibyte nil)          ;Hopefully, a no-op.
@@ -544,5 +564,6 @@ defun tar-untar-buffer ()
                (dir (if (eq (tar-header-link-type descriptor) 5)
                         name
                       (file-name-directory name)))
+               (default-directory dest-dir)
                (start (tar-header-data-start descriptor))
                (end (+ start (tar-header-size descriptor))))
