[project @ 2003-09-23 15:05:18 by simonmar]
authorsimonmar <unknown>
Tue, 23 Sep 2003 15:05:18 +0000 (15:05 +0000)
committersimonmar <unknown>
Tue, 23 Sep 2003 15:05:18 +0000 (15:05 +0000)
Fixes for the DEBUG case.

ghc/rts/Capability.c

index a2910ad..74d50ac 100644 (file)
@@ -149,9 +149,11 @@ void grabCapability(Capability** cap)
   free_capabilities = (*cap)->link;
   rts_n_free_capabilities--;
 #endif
-    IF_DEBUG(scheduler,
-            fprintf(stderr,"worker thread (%p): got capability\n",
-               osThreadId()));
+#ifdef RTS_SUPPORTS_THREADS
+  IF_DEBUG(scheduler,
+          fprintf(stderr,"worker thread (%p): got capability\n",
+                  osThreadId()));
+#endif
 }
 
 /*
@@ -199,9 +201,11 @@ void releaseCapability(Capability* cap
     signalCondition(&thread_ready_cond);
   }
 #endif
-    IF_DEBUG(scheduler,
-            fprintf(stderr,"worker thread (%p): released capability\n",
-               osThreadId()));
+#ifdef RTS_SUPPORTS_THREADS
+  IF_DEBUG(scheduler,
+          fprintf(stderr,"worker thread (%p): released capability\n",
+                  osThreadId()));
+#endif
  return;
 }