From c56129836a475962323ee34d7e0ad61b07ba1331 Mon Sep 17 00:00:00 2001 From: turbocat Date: Thu, 1 Sep 2022 19:32:56 +0000 Subject: [PATCH] SDL: Another fix for SDL_Delay. git-svn-id: svn://kolibrios.org@9875 a494cfbc-eb01-0410-851d-a64ba20cac60 --- .../sources/SDL-1.2.2_newlib/src/timer/dummy/SDL_systimer.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/contrib/sdk/sources/SDL-1.2.2_newlib/src/timer/dummy/SDL_systimer.c b/contrib/sdk/sources/SDL-1.2.2_newlib/src/timer/dummy/SDL_systimer.c index 6c90c00341..27f703769d 100755 --- a/contrib/sdk/sources/SDL-1.2.2_newlib/src/timer/dummy/SDL_systimer.c +++ b/contrib/sdk/sources/SDL-1.2.2_newlib/src/timer/dummy/SDL_systimer.c @@ -58,10 +58,7 @@ Uint32 SDL_GetTicks (void) } void SDL_Delay(unsigned ms){ - unsigned start = SDL_GetTicks(); - do{ - _ksys_delay(1); - }while (SDL_GetTicks()-start < ms); + _ksys_delay(ms/10+(ms%10>0)); } int SDL_SYS_TimerInit(void)