Changeset 4896:0cd0dc3bc104 in roaraudio for roard


Ignore:
Timestamp:
04/29/11 15:28:16 (13 years ago)
Author:
phi
Branch:
default
Phase:
public
Message:

removed useage of usleep() in flavor to nanosleep() if supported.

Location:
roard
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • roard/driver_sysclock.c

    r4708 r4896  
    113113 
    114114 if ( diff > 0 ) 
    115   usleep(diff); 
     115  roar_usleep(diff); 
    116116 
    117117 return count; 
  • roard/loop.c

    r4820 r4896  
    123123#ifdef ROAR_HAVE_USLEEP 
    124124  if ( g_standby || (streams < 1 && g_autostandby) ) { 
    125    usleep((1000000 * ROAR_OUTPUT_BUFFER_SAMPLES) / sa->rate); 
     125   roar_usleep(((uint_least32_t)1000000 * ROAR_OUTPUT_BUFFER_SAMPLES) / sa->rate); 
    126126   ROAR_DBG("usleep(%u) = ?\n", (1000000 * ROAR_OUTPUT_BUFFER_SAMPLES) / sa->rate); 
    127127  } else { 
  • roard/streams.c

    r4847 r4896  
    24272427 
    24282428#ifdef ROAR_HAVE_USLEEP 
    2429   usleep(100); // 0.1ms 
     2429  roar_usleep(100); // 0.1ms 
    24302430#endif 
    24312431 
Note: See TracChangeset for help on using the changeset viewer.