Browse Source

Bugfix: -n should show GPU count, even though GPUs aren't probed yet

Luke Dashjr 14 years ago
parent
commit
daaa489d2c
1 changed files with 3 additions and 0 deletions
  1. 3 0
      main.c

+ 3 - 0
main.c

@@ -1839,8 +1839,11 @@ static void load_default_config(void)
 }
 
 #ifdef HAVE_OPENCL
+struct device_api opencl_api;
+
 static char *print_ndevs_and_exit(int *ndevs)
 {
+	opencl_api.api_detect();
 	printf("%i GPU devices detected\n", *ndevs);
 	fflush(stdout);
 	exit(*ndevs);