Forgot to set total_devices for the purposes of finding a positive active_device.
diff --git a/main.c b/main.c
index 477417c..f8dc242 100644
--- a/main.c
+++ b/main.c
@@ -2119,6 +2119,7 @@ int main (int argc, char *argv[])
gpu_threads = nDevs * opt_g_threads;
for (i = 0; i < nDevs; i++)
gpu_devices[i] = true;
+ total_devices = nDevs;
}
if (!gpu_threads && !forced_n_threads) {