From 3b38f61a1c04009599706b6cf00f89a445a2a233 Mon Sep 17 00:00:00 2001 From: "David G. Holm" Date: Wed, 2 Jun 1999 21:06:38 +0000 Subject: [PATCH] See ChangeLog entry 19990602-16:00 EDT David G. Holm --- harbour/ChangeLog | 10 +++++++++- harbour/source/rtl/console.c | 2 ++ harbour/source/rtl/gt/gtos2.c | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 8120111867..223574a69b 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -1,5 +1,13 @@ +19990602-16:00 EDT David G. Holm + * source/rtl/console.c + - OS/2 requires that stdout and stderr be flushed in order to stay + synchronized with the GT API + * source/rtl/gt/gtos2.c + - The gtPuts function was using strlen() on the text buffer instead + of using the text length parameter + 19990602-14:50 EDT David G. Holm - * makefile.b31 + * makefile.b31 - Added itemapi.h as dependancy for arrays.obj * makefile.icc - Added new GT string modules diff --git a/harbour/source/rtl/console.c b/harbour/source/rtl/console.c index 2a04fa7ef7..593cc1d0e7 100644 --- a/harbour/source/rtl/console.c +++ b/harbour/source/rtl/console.c @@ -111,6 +111,7 @@ static void hb_outstd( char * fpStr, WORD uiLen ) char * fpPtr = fpStr; while( uiCount-- ) printf( "%c", *fpPtr++ ); + fflush( stdout ); #ifdef USE_GTAPI if( isatty( fileno( stdout ) ) ) { @@ -128,6 +129,7 @@ static void hb_outerr( char * fpStr, WORD uiLen ) char * fpPtr = fpStr; while( uiCount-- ) fprintf( stderr, "%c", *fpPtr++ ); + fflush( stderr ); #ifdef USE_GTAPI if( isatty( fileno( stdout ) ) ) { diff --git a/harbour/source/rtl/gt/gtos2.c b/harbour/source/rtl/gt/gtos2.c index 89b3be920c..401f67b479 100644 --- a/harbour/source/rtl/gt/gtos2.c +++ b/harbour/source/rtl/gt/gtos2.c @@ -100,7 +100,7 @@ int gtGetCursorStyle(void) void gtPuts(char x, char y, char attr, char *str, int len) { - VioWrtCharStrAtt(str, (USHORT) strlen(str), (USHORT) y, (USHORT) x, (PBYTE) &attr, 0); + VioWrtCharStrAtt(str, (USHORT) len, (USHORT) y, (USHORT) x, (PBYTE) &attr, 0); } void gtGetText(char x1, char y1, char x2, char y2, char *dest)