1
0
mirror of https://gitlab.xiph.org/xiph/icecast-common.git synced 2025-02-02 15:07:47 -05:00

Fix: Do not set sleeper on win* as it is not used anyway

This commit is contained in:
Philipp Schafft 2024-10-25 22:37:19 +00:00
parent 0138075df0
commit b050584d9e

View File

@ -86,6 +86,9 @@ uint64_t timing_get_time(void)
void timing_sleep(uint64_t sleeptime)
{
#ifdef WIN32
Sleep(sleeptime);
#else
struct timeval sleeper;
sleeper.tv_sec = sleeptime / 1000;
@ -96,9 +99,6 @@ void timing_sleep(uint64_t sleeptime)
* says so. The solaris manpage also says this is a legal
* value. If you think differerntly, please provide references.
*/
#ifdef WIN32
Sleep(sleeptime);
#else
select(1, NULL, NULL, NULL, &sleeper);
#endif
}