The problem was that `grease_pencil_edit_batch_ensure` would not return early if the buffers already exist, meaning that multiple buffers could be create but only the last ones would be freed. Pull Request: https://projects.blender.org/blender/blender/pulls/117580