summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Schulte <schulte.eric@gmail.com>2011-09-13 09:36:03 -0600
committerEric Schulte <schulte.eric@gmail.com>2011-09-13 09:36:03 -0600
commit0037ef9261e3d31315d9606e4bd421c1abba4c57 (patch)
tree79244b79d22d5d646bdc787666396c95591af5b3
parent597e1eb4fe7b2674c2d5233f215217f7b35e4035 (diff)
downloadorg-mode-0037ef9261e3d31315d9606e4bd421c1abba4c57.tar.gz
more robust to code blocks with empty bodies
* lisp/ob.el (org-babel-parse-src-block-match): More robust to code blocks with empty bodies.
-rw-r--r--lisp/ob.el2
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/ob.el b/lisp/ob.el
index 7c00f64..db8b50a 100644
--- a/lisp/ob.el
+++ b/lisp/ob.el
@@ -1024,7 +1024,7 @@ may be specified in the current buffer."
(if (and (> sub-length 0)
(string= "\n" (substring body sub-length)))
(substring body 0 sub-length)
- body))))
+ (or body "")))))
(preserve-indentation (or org-src-preserve-indentation
(string-match "-i\\>" switches))))
(list lang