Fix T96572: eevee crash with motion blur and stereoscopy
This was a use-after-free bug due to dangling pointers.
This commit is contained in:
parent
6aa4543462
commit
e5487a81a4
Notes:
blender-bot
2023-02-14 05:59:31 +01:00
Referenced by issue #96572, Stereoscopy with Motion Blur crashes in Eevee Referenced by issue #96241, 3.1: Potential candidates for corrective releases
|
@ -119,10 +119,12 @@ void EEVEE_motion_blur_data_free(EEVEE_MotionBlurData *mb)
|
|||
for (int i = 0; i < 2; i++) {
|
||||
if (mb->position_vbo_cache[i]) {
|
||||
BLI_ghash_free(mb->position_vbo_cache[i], NULL, (GHashValFreeFP)GPU_vertbuf_discard);
|
||||
mb->position_vbo_cache[i] = NULL;
|
||||
}
|
||||
if (mb->hair_motion_step_cache[i]) {
|
||||
BLI_ghash_free(
|
||||
mb->hair_motion_step_cache[i], NULL, (GHashValFreeFP)EEVEE_motion_hair_step_free);
|
||||
mb->hair_motion_step_cache[i] = NULL;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue