X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/1c3c4152e69745ab31273ace8cde9f2613065785..1eac1757ad2fe043df17ac10262648504c226907:/src/xbt/xbt_log_layout_format.c diff --git a/src/xbt/xbt_log_layout_format.c b/src/xbt/xbt_log_layout_format.c index d09a2fe417..9fe811b881 100644 --- a/src/xbt/xbt_log_layout_format.c +++ b/src/xbt/xbt_log_layout_format.c @@ -64,7 +64,11 @@ static double format_begin_of_time = -1; check_overflow(len); \ } else (void)0 -#define show_string(data) show_it(data, "s") +#define show_string(data) \ + if (1) { \ + const char *show_string_data = (data); \ + show_it(show_string_data ? show_string_data : "(null)", "s"); \ + } else (void)0 #define show_int(data) show_it(data, "d") #define show_double(data) show_it(data, "f")