mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-09-30 03:57:58 +00:00
Fix bug in org-babel-tangle-file with symlinked files
Assume that there is file A and symlink B that points to file A. If there is an open buffer that points to A and we call (org-babel-tangle-file "B"), then this function kills the buffer since get-file-buffer does not follow symlinks.
This commit is contained in:
parent
96cc762ff3
commit
a72466ce8d
|
@ -174,7 +174,7 @@ export file for all source blocks. Optional argument LANG can be
|
||||||
used to limit the exported source code blocks by language.
|
used to limit the exported source code blocks by language.
|
||||||
Return a list whose CAR is the tangled file name."
|
Return a list whose CAR is the tangled file name."
|
||||||
(interactive "fFile to tangle: \nP")
|
(interactive "fFile to tangle: \nP")
|
||||||
(let ((visited-p (get-file-buffer (expand-file-name file)))
|
(let ((visited-p (find-buffer-visiting (expand-file-name file)))
|
||||||
to-be-removed)
|
to-be-removed)
|
||||||
(prog1
|
(prog1
|
||||||
(save-window-excursion
|
(save-window-excursion
|
||||||
|
|
Loading…
Reference in a new issue