emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[O] ox-html problem exposed by ox-S5


From: Eric Schulte
Subject: [O] ox-html problem exposed by ox-S5
Date: Mon, 29 Jul 2013 15:36:01 -0600
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

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.

>From 07d6c3d1943b2b6fe63ddc107c4c127c9b70b209 Mon Sep 17 00:00:00 2001
From: Eric Schulte <address@hidden>
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

Cheers,

-- 
Eric Schulte
http://cs.unm.edu/~eschulte
PGP fingerprint: FA8D C2C3 E8A0 A749 34CD  9DCF 3C1B 8581 614C A05D

reply via email to

[Prev in Thread] Current Thread [Next in Thread]