[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] [SCM] Gnash branch, master, updated. f693e96d590ee1d4020e
From: |
Benjamin Wolsey |
Subject: |
[Gnash-commit] [SCM] Gnash branch, master, updated. f693e96d590ee1d4020edc82de7f638d5d080e7c |
Date: |
Thu, 21 Oct 2010 13:58:27 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Gnash".
The branch, master has been updated
via f693e96d590ee1d4020edc82de7f638d5d080e7c (commit)
from a2938126c00bb70b00e661eb5b7aa7f3ce7a6706 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit//commit/?id=f693e96d590ee1d4020edc82de7f638d5d080e7c
commit f693e96d590ee1d4020edc82de7f638d5d080e7c
Author: Benjamin Wolsey <address@hidden>
Date: Thu Oct 21 15:57:55 2010 +0200
Use nanosleep instead of the deprecated usleep.
diff --git a/libbase/GnashSleep.h b/libbase/GnashSleep.h
index 0145a88..afda3fb 100644
--- a/libbase/GnashSleep.h
+++ b/libbase/GnashSleep.h
@@ -24,7 +24,7 @@
#if defined(_WIN32) || defined(WIN32)
# include <windows.h>
#else
-# include <unistd.h>
+# include <time.h>
#endif
namespace gnash {
@@ -37,7 +37,9 @@ inline void gnashSleep(size_t useconds)
#if defined(_WIN32) || defined(WIN32)
Sleep(useconds / 1000);
#else
- usleep(useconds);
+ const size_t m = 1000000;
+ const struct timespec t = { useconds / m, (useconds % m) * 1000 };
+ ::nanosleep(&t, 0);
#endif
}
-----------------------------------------------------------------------
Summary of changes:
libbase/GnashSleep.h | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
hooks/post-receive
--
Gnash
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gnash-commit] [SCM] Gnash branch, master, updated. f693e96d590ee1d4020edc82de7f638d5d080e7c,
Benjamin Wolsey <=