Explorar o código

Fix dead assignment.

[scan-build] Dead assignment.
Cyril Roelandt %!s(int64=13) %!d(string=hai) anos
pai
achega
f44b57b8b1
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      src/drivers/cuda/driver_cuda.c

+ 2 - 0
src/drivers/cuda/driver_cuda.c

@@ -214,6 +214,8 @@ static int execute_job_on_cuda(starpu_job_t j, struct starpu_worker_s *args)
 #ifdef HAVE_CUDA_MEMCPY_PEER
 	/* We make sure we do manipulate the proper device */
 	cures = cudaSetDevice(args->devid);
+	if (STARPU_UNLIKELY(cures != cudaSuccess))
+		STARPU_CUDA_REPORT_ERROR(cures);
 #endif
 
 	if (cl->cuda_func != STARPU_MULTIPLE_CUDA_IMPLEMENTATIONS) {