Pārlūkot izejas kodu

Fix macro for use directly in an if

Samuel Thibault 13 gadi atpakaļ
vecāks
revīzija
5abb0b8256
1 mainītis faili ar 2 papildinājumiem un 2 dzēšanām
  1. 2 2
      src/common/utils.h

+ 2 - 2
src/common/utils.h

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
  *
- * Copyright (C) 2010  Université de Bordeaux 1
+ * Copyright (C) 2010, 2012  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012  Centre National de la Recherche Scientifique
  * Copyright (C) 2010, 2011, 2012  Centre National de la Recherche Scientifique
  *
  *
  * StarPU is free software; you can redistribute it and/or modify
  * StarPU is free software; you can redistribute it and/or modify
@@ -30,7 +30,7 @@
 #ifdef STARPU_VERBOSE
 #ifdef STARPU_VERBOSE
 #  define _STARPU_DEBUG(fmt, args ...) do { if (!getenv("STARPU_SILENT")) {fprintf(stderr, "[starpu][%s] " fmt ,__func__ ,##args); fflush(stderr); }} while(0)
 #  define _STARPU_DEBUG(fmt, args ...) do { if (!getenv("STARPU_SILENT")) {fprintf(stderr, "[starpu][%s] " fmt ,__func__ ,##args); fflush(stderr); }} while(0)
 #else
 #else
-#  define _STARPU_DEBUG(fmt, args ...)
+#  define _STARPU_DEBUG(fmt, args ...) do { } while (0)
 #endif
 #endif
 
 
 #ifdef STARPU_VERBOSE0
 #ifdef STARPU_VERBOSE0