~ubuntu-branches/ubuntu/raring/libcaca/raring

« back to all changes in this revision

Viewing changes to caca/time.c

  • Committer: Bazaar Package Importer
  • Author(s): Sam Hocevar
  • Date: 2010-02-08 01:40:59 UTC
  • mfrom: (1.1.8 upstream) (4.1.6 sid)
  • Revision ID: james.westby@ubuntu.com-20100208014059-9q4av8pze8p7uw3i
Tags: 0.99.beta17-1
New upstream release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
2
 *  libcaca       Colour ASCII-Art library
3
 
 *  Copyright (c) 2002-2006 Sam Hocevar <sam@zoy.org>
 
3
 *  Copyright (c) 2002-2006 Sam Hocevar <sam@hocevar.net>
4
4
 *                All Rights Reserved
5
5
 *
6
 
 *  $Id$
7
 
 *
8
6
 *  This library is free software. It comes without any warranty, to
9
7
 *  the extent permitted by applicable law. You can redistribute it
10
8
 *  and/or modify it under the terms of the Do What The Fuck You Want
38
36
void _caca_sleep(int usec)
39
37
{
40
38
#if defined(HAVE_USLEEP)
41
 
        usleep(usec);
 
39
    usleep(usec);
42
40
#elif defined(HAVE_SLEEP)
43
 
        Sleep(usec / 1000);
 
41
    Sleep((usec + 500) / 1000);
44
42
#else
45
 
        /* SLEEP */
 
43
    /* SLEEP */
46
44
#endif
47
45
}
48
46