From: Martin Townsend Date: Wed, 9 Jul 2014 20:46:54 +0000 (-0400) Subject: Fix: add missing URCU_TLS to logging time variable X-Git-Tag: v2.6.0-rc1~159 X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=commitdiff_plain;h=f79e29fef18e8dfea79dae67d5bebd613a75de3a Fix: add missing URCU_TLS to logging time variable Signed-off-by: David Goulet --- diff --git a/src/common/error.c b/src/common/error.c index 418fc47ab..5abb7453a 100644 --- a/src/common/error.c +++ b/src/common/error.c @@ -49,14 +49,14 @@ const char *log_add_time(void) } /* Format time in the TLS variable. */ - ret = snprintf(error_log_time.str, sizeof(error_log_time.str), + ret = snprintf(URCU_TLS(error_log_time).str, sizeof(error_log_time.str), "%02d:%02d:%02d.%06ld", tm.tm_hour, tm.tm_min, tm.tm_sec, tp.tv_nsec); if (ret < 0) { goto error; } - return error_log_time.str; + return URCU_TLS(error_log_time).str; error: /* Return an empty string on error so logging is not affected. */