diff options
author | Bastien Guerry <bzg@bzg.fr> | 2020-06-05 14:50:27 +0200 |
---|---|---|
committer | Bastien Guerry <bzg@bzg.fr> | 2020-06-05 14:50:27 +0200 |
commit | 706970efb1d86cf5a8e2eba3d8cd894138a0c333 (patch) | |
tree | a1e96c90df35502cc21a30ab28541c43a9e7439c | |
parent | fa4dddf8d29063dbd2161b7f33a776e2c063ed10 (diff) | |
download | org-mode-706970efb1d86cf5a8e2eba3d8cd894138a0c333.tar.gz |
ox-texinfo.el: Fix escaping special chars in raw-path
* lisp/ox-texinfo.el (org-texinfo-link): Escape @, { and }
characters in the link path.
-rw-r--r-- | lisp/ox-texinfo.el | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lisp/ox-texinfo.el b/lisp/ox-texinfo.el index 4265a85..f39a39d 100644 --- a/lisp/ox-texinfo.el +++ b/lisp/ox-texinfo.el @@ -1046,7 +1046,10 @@ DESC is the description part of the link, or the empty string. INFO is a plist holding contextual information. See `org-export-data'." (let* ((type (org-element-property :type link)) - (raw-path (org-element-property :path link)) + (raw-path + (replace-regexp-in-string + "[@{}]" "@\\&" + (org-element-property :path link))) ;; Ensure DESC really exists, or set it to nil. (desc (and (not (string= desc "")) desc)) (path (cond |