Files
test/source
Philipp Oeser 11db0b9dad Fix #118524: Loopcut crashes when not near an edge
Caused by 1c0f374ec3

When `EDBM_edge_find_nearest_ex` does not find a nearest edge in
`loopcut_mouse_move`, then  `loopcut_update_edge` will set
`RingSelOpData` `ob` to nullptr (rightfully so).

This would then crash in `ringsel_draw` (because we are trying to call
`object_to_world()` on the nullptr).

Prior to 1c0f374ec3 this was also "wrong", but
`EDBM_preselect_edgering_draw` would early out before using garbage
data.

Now guard against this and dont call `EDBM_preselect_edgering_draw` at
all if we dont have valid input.

Pull Request: https://projects.blender.org/blender/blender/pulls/118549
2024-02-21 12:38:06 +01:00
..