aboutsummaryrefslogtreecommitdiff
path: root/src/cuda.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/cuda.c')
-rw-r--r--src/cuda.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/cuda.c b/src/cuda.c
index 0c42d74..3076ebe 100644
--- a/src/cuda.c
+++ b/src/cuda.c
@@ -37,15 +37,13 @@ bool gsr_cuda_load(gsr_cuda *self) {
{ NULL, NULL }
};
+ CUresult res;
+
if(!dlsym_load_list(lib, required_dlsym)) {
fprintf(stderr, "gsr error: gsr_cuda_load failed: missing required symbols in libcuda.so/libcuda.so.1\n");
- dlclose(lib);
- memset(self, 0, sizeof(gsr_cuda));
- return false;
+ goto fail;
}
- CUresult res;
-
res = self->cuInit(0);
if(res != CUDA_SUCCESS) {
const char *err_str = "unknown";