org.el (org-do-emphasis-faces): Fix false positives handling
commitf21150f1853180f63741083e427ef4e6bec1ea52
authorBastien Guerry <bzg@altern.org>
Fri, 3 Jan 2014 10:16:14 +0000 (3 11:16 +0100)
committerBastien Guerry <bzg@altern.org>
Fri, 3 Jan 2014 10:16:14 +0000 (3 11:16 +0100)
treeb7e63698d42ba6a71e8b27383c8d593fe9ebf0d3
parent9758f203fba8949658cbc462509e1a61b3364199
org.el (org-do-emphasis-faces): Fix false positives handling

* org.el (org-do-emphasis-faces): Handle false positives by
restarting the re-search one char after the beginning of the
match, not one char before its ending.

Before this fix, consider this buffer

** Headline
  - *Bold* non-bold
  - *Bold* non-bold

The first false positive is "** Headline\n  - *Bold*"

Starting the search again from the last "*" will skip
the "*Bold*" string.  Starting again at "* Headline" will
find it.
lisp/org.el