Commit 08f56f5f2f66b492afdb6573d7694262eff60a9d

Con Kolivas 2011-06-26T08:55:53

Set default CPU threads to 0 if GPU mining.

diff --git a/cpu-miner.c b/cpu-miner.c
index 9edd6f5..25a8448 100644
--- a/cpu-miner.c
+++ b/cpu-miner.c
@@ -220,7 +220,7 @@ static struct option_help options_help[] = {
 #endif
 
 	{ "threads N",
-	  "(-t N) Number of miner CPU threads (default: number of processors)" },
+	  "(-t N) Number of miner CPU threads (default: number of processors or 0 if GPU mining)" },
 
 	{ "url URL",
 	  "URL for bitcoin JSON-RPC server "
@@ -1293,6 +1293,8 @@ int main (int argc, char *argv[])
 		applog(LOG_INFO, "%i", nDevs);
 		return nDevs;
 	}
+	if (nDevs)
+		opt_n_threads = 0;
 
 	rpc_url = strdup(DEF_RPC_URL);