ox-texinfo.el: Fix escaping special chars in raw-path

* lisp/ox-texinfo.el (org-texinfo-link): Escape @, { and }
characters in the link path.
This commit is contained in:
Bastien Guerry 2020-06-05 14:50:27 +02:00
parent fa4dddf8d2
commit 706970efb1

View file

@ -1046,7 +1046,10 @@ DESC is the description part of the link, or the empty string.
INFO is a plist holding contextual information. See INFO is a plist holding contextual information. See
`org-export-data'." `org-export-data'."
(let* ((type (org-element-property :type link)) (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. ;; Ensure DESC really exists, or set it to nil.
(desc (and (not (string= desc "")) desc)) (desc (and (not (string= desc "")) desc))
(path (cond (path (cond