From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Schulte Subject: ox-html problem exposed by ox-S5 Date: Mon, 29 Jul 2013 15:36:01 -0600 Message-ID: <87ppu1t5fi.fsf@gmail.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35221) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V3v9f-0001xa-RJ for emacs-orgmode@gnu.org; Mon, 29 Jul 2013 17:39:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V3v9a-0004aH-MC for emacs-orgmode@gnu.org; Mon, 29 Jul 2013 17:38:59 -0400 Received: from mail-pd0-x22b.google.com ([2607:f8b0:400e:c02::22b]:46102) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V3v9a-0004a6-GJ for emacs-orgmode@gnu.org; Mon, 29 Jul 2013 17:38:54 -0400 Received: by mail-pd0-f171.google.com with SMTP id y14so5899240pdi.2 for ; Mon, 29 Jul 2013 14:38:53 -0700 (PDT) Received: from bagel (c-174-56-50-60.hsd1.nm.comcast.net. [174.56.50.60]) by mx.google.com with ESMTPSA id qg10sm78978040pbb.2.2013.07.29.14.38.49 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 29 Jul 2013 14:38:52 -0700 (PDT) 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: Org Mode Mailing List --=-=-= Content-Type: text/plain Hi, While moving to the ox-s5 backend, which is very nice (thanks Rick), I noticed a bug in ox-html. The attached patch fixes this problem. --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-check-html-link-home-exists-before-triming.patch >From 07d6c3d1943b2b6fe63ddc107c4c127c9b70b209 Mon Sep 17 00:00:00 2001 From: Eric Schulte Date: Mon, 29 Jul 2013 15:19:22 -0600 Subject: [PATCH] check html-link-home exists before triming Ensure that the :html-link-home property exists before passing it to `org-trim' which assumes it's argument is a string. --- lisp/ox-html.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lisp/ox-html.el b/lisp/ox-html.el index 9fc53f1..2522f63 100644 --- a/lisp/ox-html.el +++ b/lisp/ox-html.el @@ -2598,7 +2598,8 @@ images, set it to: DESC is the description part of the link, or the empty string. INFO is a plist holding contextual information. See `org-export-data'." - (let* ((home (org-trim (plist-get info :html-link-home))) + (let* ((home (when (plist-get info :html-link-home) + (org-trim (plist-get info :html-link-home)))) (use-abs-url (plist-get info :html-link-use-abs-url)) (link-org-files-as-html-maybe (function -- 1.8.3.4 --=-=-= Content-Type: text/plain Cheers, -- Eric Schulte http://cs.unm.edu/~eschulte PGP fingerprint: FA8D C2C3 E8A0 A749 34CD 9DCF 3C1B 8581 614C A05D --=-=-=--