1
0
mirror of https://github.com/hashcat/hashcat.git synced 2024-12-17 04:08:34 +00:00

Use a rc for first result, easier to read

This commit is contained in:
Jens Steube 2016-01-30 22:47:13 +01:00
parent 0141ef9e8f
commit 9aea991424

View File

@ -2430,10 +2430,12 @@ static void run_kernel (const uint kern_run, hc_device_param_t *device_param, co
}
else
{
const size_t global_work_size[3] = { num_elements, 1, 1 };
const size_t global_work_size[3] = { num_elements, 1, 1 };
const size_t local_work_size[3] = { kernel_threads, 1, 1 };
if (hc_clEnqueueNDRangeKernel (data.ocl, device_param->command_queue, kernel, 1, NULL, global_work_size, local_work_size, 0, NULL, NULL, false) != CL_SUCCESS)
const cl_int rc = hc_clEnqueueNDRangeKernel (data.ocl, device_param->command_queue, kernel, 1, NULL, global_work_size, local_work_size, 0, NULL, NULL, false);
if (rc != CL_SUCCESS)
{
const size_t local_work_size_fallback[3] = { 1, 1, 1 };
@ -2502,7 +2504,9 @@ static void run_kernel_mp (const uint kern_run, hc_device_param_t *device_param,
const size_t global_work_size[3] = { num_elements, 1, 1 };
const size_t local_work_size[3] = { kernel_threads, 1, 1 };
if (hc_clEnqueueNDRangeKernel (data.ocl, device_param->command_queue, kernel, 1, NULL, global_work_size, local_work_size, 0, NULL, NULL, false) != CL_SUCCESS)
const cl_int rc = hc_clEnqueueNDRangeKernel (data.ocl, device_param->command_queue, kernel, 1, NULL, global_work_size, local_work_size, 0, NULL, NULL, false);
if (rc != CL_SUCCESS)
{
const size_t local_work_size_fallback[3] = { 1, 1, 1 };