diff options
author | Guido van Rossum <guido@python.org> | 1993-07-05 10:31:29 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 1993-07-05 10:31:29 (GMT) |
commit | f1dc56632881fe4e5beed047580bf927679f3669 (patch) | |
tree | f669dcac15ec9cb2801b881c3a7b1a579e7c994e /Modules/timemodule.c | |
parent | 9e90a672b44e2acfd5c6dabfb9435bb4bb46c845 (diff) | |
download | cpython-f1dc56632881fe4e5beed047580bf927679f3669.zip cpython-f1dc56632881fe4e5beed047580bf927679f3669.tar.gz cpython-f1dc56632881fe4e5beed047580bf927679f3669.tar.bz2 |
* Makefile: added all: and default: targets.
* many files: made some functions static; removed "extern int errno;".
* frozenmain.c: fixed bugs introduced on 24 June...
* flmodule.c: remove 1.5 bw compat hacks, add new functions in 2.2a
(and some old functions that were omitted).
* timemodule.c: added MSDOS floatsleep version .
* pgenmain.c: changed exit() to goaway() and added defn of goaway().
* intrcheck.c: add hack (to UNIX only) so interrupting 3 times
will exit from a hanging program. The second interrupt prints
a message explaining this to the user.
Diffstat (limited to 'Modules/timemodule.c')
-rw-r--r-- | Modules/timemodule.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/Modules/timemodule.c b/Modules/timemodule.c index 097c4da..68c5ac7 100644 --- a/Modules/timemodule.c +++ b/Modules/timemodule.c @@ -469,7 +469,7 @@ floatsleep(secs) #endif /* unix */ -#ifdef TURBO_C /* Maybe also for MS-DOS? */ +#ifdef TURBO_C #ifndef CLOCKS_PER_SEC #define CLOCKS_PER_SEC 55 /* 54.945 msec per tick (18.2 HZ clock) */ @@ -492,3 +492,14 @@ millitimer() } #endif /* TURBO_C */ + +#ifdef MSDOS + +floatsleep(secs) + double secs; +{ + clock_t t= clock( ); + while( (clock()-t)/CLOCKS_PER_SEC<secs ) + ; +} +#endif /* MSDOS */ |