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 <bdwalton@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Ben Walton committed
Sep 28, 2014 at 08:50 UTC
6433d569753e8d33d3f7beca16a65f2fc481aade
1 file changed
+1
-1
trace.c
+1
-1
@@ -384,7 +384,7 @@ static inline uint64_t gettimeofday_nanos(void)
384
* Returns nanoseconds since the epoch (01/01/1970), for performance tracing
385
* (i.e. favoring high precision over wall clock time accuracy).
386
*/
387
-inline uint64_t getnanotime(void)
387
+uint64_t getnanotime(void)
388
{
389
static uint64_t offset;
390
if (offset > 1) {