From 62f62cf90364040706863bd574d340e7c82216c3 Mon Sep 17 00:00:00 2001 From: Gary Scavone Date: Tue, 22 Aug 2017 17:44:02 -0700 Subject: [PATCH] Fix to initialize lastTickTimestamp when setting stream time. --- RtAudio.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/RtAudio.cpp b/RtAudio.cpp index 1611e09..5d49366 100644 --- a/RtAudio.cpp +++ b/RtAudio.cpp @@ -428,6 +428,9 @@ void RtApi :: setStreamTime( double time ) if ( time >= 0.0 ) stream_.streamTime = time; +#if defined( HAVE_GETTIMEOFDAY ) + gettimeofday( &stream_.lastTickTimestamp, NULL ); +#endif } unsigned int RtApi :: getStreamSampleRate( void ) -- 2.30.2