2 * Misc. functions for systems that don't have them
4 * Copyright 1996 Alexandre Julliard
13 unsigned int usleep (unsigned int useconds
) { DosSleep(useconds
); }
15 unsigned int usleep (unsigned int useconds
)
20 delay
.tv_usec
= useconds
;
22 select( 0, 0, 0, 0, &delay
);
26 #endif /* HAVE_USLEEP */
29 void *memmove( void *dest
, const void *src
, unsigned int len
)
31 register char *dst
= dest
;
33 /* Use memcpy if not overlapping */
34 if ((dst
+ len
<= (char *)src
) || ((char *)src
+ len
<= dst
))
36 memcpy( dst
, src
, len
);
38 /* Otherwise do it the hard way (FIXME: could do better than this) */
41 while (len
--) *dst
++ = *((char *)src
)++;
46 src
= (char *)src
+ len
- 1;
47 while (len
--) *dst
-- = *((char *)src
)--;
51 #endif /* HAVE_MEMMOVE */