Skip to content

Commit

Permalink
Merge pull request #142 from jrblevin/out-of-range-error
Browse files Browse the repository at this point in the history
Don't return point which is larger than point-max
  • Loading branch information
syohex committed May 27, 2016
2 parents c560ddd + 360a7bb commit 437713d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion markdown-mode.el
Original file line number Diff line number Diff line change
Expand Up @@ -1520,7 +1520,7 @@ Function is called repeatedly until it returns nil. For details, see
(code-match (markdown-code-block-at-pos end))
(new-end (or (and code-match (cl-second code-match)) new-end)))
(unless (and (eq new-start start) (eq new-end end))
(cons new-start new-end))))))
(cons new-start (min new-end (point-max))))))))

(defun markdown-font-lock-extend-region-function (start end _)
"Used in `jit-lock-after-change-extend-region-functions'.
Expand Down

0 comments on commit 437713d

Please sign in to comment.