[vlc-commits] commit: cosmetic fix (=?UTF-8?Q?R=C3=A9mi=20Denis=2DCourmont=20?=)

git at videolan.org git at videolan.org
Wed Nov 24 17:43:24 CET 2010


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Wed Nov 24 18:43:16 2010 +0200| [8d622c5bb504d48e4b1ad60b55f9f9a9839d15b6] | committer: Rémi Denis-Courmont 

cosmetic fix

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

 src/misc/pthread.c |   42 +++++++++++++++++++++---------------------
 1 files changed, 21 insertions(+), 21 deletions(-)

diff --git a/src/misc/pthread.c b/src/misc/pthread.c
index 761493b..7603b24 100644
--- a/src/misc/pthread.c
+++ b/src/misc/pthread.c
@@ -819,27 +819,27 @@ static void *vlc_timer_thread (void *data)
 
     for (;;)
     {
-         mwait (value);
-
-         int canc = vlc_savecancel ();
-         timer->func (timer->data);
-         vlc_restorecancel (canc);
-
-         if (interval == 0)
-             return NULL;
-
-         mtime_t now = mdate ();
-         unsigned misses = (now - value) / interval;
-         /* Try to compensate for one miss (mwait() will return immediately)
-          * but no more. Otherwise, we might busy loop, after extended periods
-          * without scheduling (suspend, SIGSTOP, RT preemption, ...). */
-         if (misses > 1)
-         {
-             misses--;
-             vlc_atomic_add (&timer->overruns, misses);
-             value += misses * interval;
-         }
-         value += interval;
+        mwait (value);
+
+        int canc = vlc_savecancel ();
+        timer->func (timer->data);
+        vlc_restorecancel (canc);
+
+        if (interval == 0)
+            return NULL;
+
+        mtime_t now = mdate ();
+        unsigned misses = (now - value) / interval;
+        /* Try to compensate for one miss (mwait() will return immediately)
+         * but no more. Otherwise, we might busy loop, after extended periods
+         * without scheduling (suspend, SIGSTOP, RT preemption, ...). */
+        if (misses > 1)
+        {
+            misses--;
+            vlc_atomic_add (&timer->overruns, misses);
+            value += misses * interval;
+        }
+        value += interval;
     }
 }
 



More information about the vlc-commits mailing list