From c7020c00ca6ff3022638dcc8ca74e6b305dd31cf Mon Sep 17 00:00:00 2001 From: hyung-hwan Date: Mon, 18 Apr 2011 09:38:21 +0000 Subject: [PATCH] touched up awk a bit more for OS/2 --- qse/cmd/awk/awk.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/qse/cmd/awk/awk.c b/qse/cmd/awk/awk.c index dbe3cfe2..b2b5fd61 100644 --- a/qse/cmd/awk/awk.c +++ b/qse/cmd/awk/awk.c @@ -1,5 +1,5 @@ /* - * $Id: awk.c 437 2011-04-17 15:32:02Z hyunghwan.chung $ + * $Id: awk.c 438 2011-04-17 15:38:21Z hyunghwan.chung $ * Copyright 2006-2009 Chung, Hyung-Hwan. This file is part of QSE. @@ -42,6 +42,7 @@ # include # include #elif defined(__OS2__) +# define INCL_DOSPROCESS # define INCL_DOSEXCEPTIONS # define INCL_ERRORS # include @@ -332,9 +333,12 @@ static int fnc_sleep (qse_awk_rtx_t* run, const qse_cstr_t* fnm) if (n == -1) return -1; if (n == 1) lv = (qse_long_t)rv; -#ifdef _WIN32 +#if defined(_WIN32) Sleep ((DWORD)(lv * 1000)); n = 0; +#elif defined(__OS2__) + DosSleep ((ULONG)(lv * 1000)); + n = 0; #else n = sleep (lv); #endif