From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bastien Subject: Re: Orgmode fails to export specific web-links as latex/pdf Date: Tue, 09 Jul 2013 13:14:31 +0200 Message-ID: <87y59gt27c.fsf@bzg.ath.cx> References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:48884) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UwY3i-0006ZC-0U for emacs-orgmode@gnu.org; Tue, 09 Jul 2013 09:34:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UwY3g-00024O-QC for emacs-orgmode@gnu.org; Tue, 09 Jul 2013 09:34:21 -0400 Received: from mail-we0-x22e.google.com ([2a00:1450:400c:c03::22e]:41472) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UwY3g-00024H-L9 for emacs-orgmode@gnu.org; Tue, 09 Jul 2013 09:34:20 -0400 Received: by mail-we0-f174.google.com with SMTP id q58so4724344wes.19 for ; Tue, 09 Jul 2013 06:34:19 -0700 (PDT) In-Reply-To: (Mark Edgington's message of "Mon, 8 Jul 2013 22:16:49 -0400") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Mark Edgington Cc: emacs-orgmode --=-=-= Content-Type: text/plain Hi Mark, I confirm this bug: "%" in links breaks the export. The attached patch is a quick fix, but it needs to be double-checked and surely amended. Also, I didn't check other link-related functions. Thanks for reporting this bad bug, --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=fix-latex-percent-char-in-links.patch diff --git a/lisp/ox-latex.el b/lisp/ox-latex.el index aa30cf1..650b7cc 100644 --- a/lisp/ox-latex.el +++ b/lisp/ox-latex.el @@ -1748,7 +1748,9 @@ 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 (org-latex-plain-text + (org-link-escape (org-element-property :path link)) + info)) ;; Ensure DESC really exists, or set it to nil. (desc (and (not (string= desc "")) desc)) (imagep (org-export-inline-image-p --=-=-= Content-Type: text/plain -- Bastien --=-=-=--