--- os2sdk/demos/examples/sleep/sleep.c 2018/08/09 12:25:13 1.1 +++ os2sdk/demos/examples/sleep/sleep.c 2018/08/09 12:26:20 1.1.1.2 @@ -1,5 +1,5 @@ /* - * Example of DOSSLEEP usage + * Example of DosSleep usage * * This call suspends the execution, of the process or thread which issues * the call, for the specified abount of time. Other processes and threads @@ -10,27 +10,28 @@ * * Compile as: cl -AL -Lp -G0 sleep.c * - * Copyright (C) Microsoft Corp. 1986 + * Created by Microsoft Corp. 1986 */ -#include +#define INCL_DOSPROCESS -extern long atol(); +#include +#include main(argc, argv) int argc; char *argv[]; { - unsigned long TimeInterval; /* Number of milliseconds to delay */ + ULONG TimeInterval; /* Number of milliseconds to delay */ if(argc > 1) TimeInterval = atol(argv[1]); /* user specified delay */ else - TimeInterval = (long)2000; /* default 2 seconds */ + TimeInterval = 2000L; /* default 2 seconds */ printf("Sleeping for %ld milliseconds.\n", TimeInterval); - DOSSLEEP(TimeInterval); + DosSleep(TimeInterval); printf("Sleep completed.\n"); }