Cycles: Fix crash after failed kernel build

Pointers to kernels were uninitialized leading to freeing of random memory
addresses. Another reason it would be good to use smart pointers.
This commit is contained in:
Mai Lavelle 2017-03-04 03:29:03 -05:00
parent 18e50927f7
commit 997e345bd2
1 changed files with 11 additions and 0 deletions

View File

@ -31,6 +31,17 @@ DeviceSplitKernel::DeviceSplitKernel(Device *device) : device(device)
first_tile = true;
avg_time_per_sample = 0.0;
kernel_path_init = NULL;
kernel_scene_intersect = NULL;
kernel_lamp_emission = NULL;
kernel_queue_enqueue = NULL;
kernel_background_buffer_update = NULL;
kernel_shader_eval = NULL;
kernel_holdout_emission_blurring_pathtermination_ao = NULL;
kernel_direct_lighting = NULL;
kernel_shadow_blocked = NULL;
kernel_next_iteration_setup = NULL;
}
DeviceSplitKernel::~DeviceSplitKernel()