Commit 78d6bee137f786fb35ce6c5f6c8725b3ad363b53

Con Kolivas 2013-05-30T12:03:16

Inverted sem_init logic.

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/cgminer.c b/cgminer.c
index 8451f69..fab2781 100644
--- a/cgminer.c
+++ b/cgminer.c
@@ -7374,7 +7374,7 @@ int main(int argc, char *argv[])
 
 	// before device detection
 	if (!opt_scrypt) {
-		if (!sem_init(&usb_resource_sem, 0, 0))
+		if (sem_init(&usb_resource_sem, 0, 0))
 			quit(1, "Failed to sem_init usb_resource_sem");
 		usbres_thr_id = 1;
 		thr = &control_thr[usbres_thr_id];