diff options
author | Thomas White <taw@physics.org> | 2011-03-04 18:15:15 +0100 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2012-02-22 15:27:17 +0100 |
commit | 0ccec37b8c836c1409b4b282cf3bc6febefe3021 (patch) | |
tree | a29c4a45b8a0736401672e4b964de3b2343f9318 /src/diffraction-gpu.c | |
parent | 9357d8f186760fda060fe3324d88480c877c21f3 (diff) |
Check errors properly
Diffstat (limited to 'src/diffraction-gpu.c')
-rw-r--r-- | src/diffraction-gpu.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/diffraction-gpu.c b/src/diffraction-gpu.c index 176e2e7b..9b96f112 100644 --- a/src/diffraction-gpu.c +++ b/src/diffraction-gpu.c @@ -205,14 +205,14 @@ void get_diffraction_gpu(struct gpu_context *gctx, struct image *image, if ( set_arg_mem(gctx, 18, gctx->flags) ) return; /* Unit cell */ - clSetKernelArg(gctx->kern, 8, sizeof(cl_float16), &cell); + err = clSetKernelArg(gctx->kern, 8, sizeof(cl_float16), &cell); if ( err != CL_SUCCESS ) { ERROR("Couldn't set unit cell: %s\n", clError(err)); return; } /* Local memory for reduction */ - clSetKernelArg(gctx->kern, 13, + err = clSetKernelArg(gctx->kern, 13, BWSAMPLING*SAMPLING*SAMPLING*sizeof(cl_float), NULL); if ( err != CL_SUCCESS ) { ERROR("Couldn't set local memory: %s\n", clError(err)); |