[vlc-commits] darwin:thread: fix vlc_cond_timedwait_daytime() deadline handling

Steve Lhomme git at videolan.org
Wed Jul 4 10:39:16 CEST 2018


vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Wed Jul  4 09:23:31 2018 +0200| [56c9cc5879e28ef5d8d9eaab40253d0b122bef30] | committer: Steve Lhomme

darwin:thread: fix vlc_cond_timedwait_daytime() deadline handling

The deadline received is a time_t not a vlc_tick_t

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=56c9cc5879e28ef5d8d9eaab40253d0b122bef30
---

 src/darwin/thread.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/darwin/thread.c b/src/darwin/thread.c
index 7b0dfdb290..7481ac7d49 100644
--- a/src/darwin/thread.c
+++ b/src/darwin/thread.c
@@ -285,7 +285,7 @@ int vlc_cond_timedwait_daytime (vlc_cond_t *p_condvar, vlc_mutex_t *p_mutex,
      * time deadline is passed, even if the real time is adjusted in between.
      * This is not fulfilled, as described above.
      */
-    struct timespec ts = mtime_to_ts(deadline);
+    struct timespec ts = { deadline, 0 };
     int val = pthread_cond_timedwait(p_condvar, p_mutex, &ts);
 
     if (val != ETIMEDOUT)



More information about the vlc-commits mailing list