Browse Source

Get the device number from the thread id, not the other way around.

Con Kolivas 14 years ago
parent
commit
5fd73374b3
1 changed files with 1 additions and 1 deletions
  1. 1 1
      main.c

+ 1 - 1
main.c

@@ -1925,7 +1925,7 @@ static bool active_device(int thr_id)
 	if (thr_id < gpu_threads) {
 		if (thr_id > nDevs)
 			return false;
-		if (!gpu_devices[thr_id])
+		if (!gpu_devices[dev_from_id(thr_id)])
 			return false;
 	} else if (thr_id > gpu_threads + num_processors)
 		return false;