From: Ben Walton Date: Sun, 28 Sep 2014 07:50:26 +0000 (+0100) Subject: trace.c: do not mark getnanotime() as "inline" X-Git-Tag: v2.2.0-rc0~44^2 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/6433d569753e8d33d3f7beca16a65f2fc481aade?ds=inline;hp=--cc trace.c: do not mark getnanotime() as "inline" Oracle Studio compilers don't allow for static variables in functions that are defined to be inline. GNU C does permit this. Let's reference the C99 standard though, which doesn't allow for inline functions to contain modifiable static variables. Signed-off-by: Ben Walton Signed-off-by: Junio C Hamano --- 6433d569753e8d33d3f7beca16a65f2fc481aade diff --git a/trace.c b/trace.c index e583dc63bb..03990df747 100644 --- a/trace.c +++ b/trace.c @@ -384,7 +384,7 @@ static inline uint64_t gettimeofday_nanos(void) * Returns nanoseconds since the epoch (01/01/1970), for performance tracing * (i.e. favoring high precision over wall clock time accuracy). */ -inline uint64_t getnanotime(void) +uint64_t getnanotime(void) { static uint64_t offset; if (offset > 1) {