]> git.eshelyaron.com Git - emacs.git/commit
Avoid assertion violations in treesit.c with --enable-checking
authorEli Zaretskii <eliz@gnu.org>
Thu, 29 Dec 2022 11:52:09 +0000 (13:52 +0200)
committerEli Zaretskii <eliz@gnu.org>
Thu, 29 Dec 2022 11:52:09 +0000 (13:52 +0200)
commit706ed85285515e7047e16608815c1d02d4907b07
tree49362a14e2f60b2715a8b2e1e97e11463a93fbd8
parent38c35bf0f6a938001dfecbe439addf8fb62897c6
Avoid assertion violations in treesit.c with --enable-checking

* src/treesit.c (Ftreesit_node_first_child_for_pos)
(Ftreesit_node_descendant_for_range): Check validity of buffer
positions before converting them to byte-positions, to avoid
assertion violations in buf_charpos_to_bytepos.
src/treesit.c