diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 79e723ff63..c8c63b12d7 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -17,6 +17,11 @@ past entries belonging to author(s): Viktor Szakats. */ +2009-12-19 11:22 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl) + * harbour/src/rtl/gtwin/gtwin.c + ! applied Xavi's patch fixing CTRL+C error handler setting in newly + allocated consoles + 2009-12-18 22:13 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com) * contrib/hbqt/qth/QCoreApplication.qth * contrib/hbqt/qth/QErrorMessage.qth diff --git a/harbour/src/rtl/gtwin/gtwin.c b/harbour/src/rtl/gtwin/gtwin.c index 58b730bf66..bb93e8962f 100644 --- a/harbour/src/rtl/gtwin/gtwin.c +++ b/harbour/src/rtl/gtwin/gtwin.c @@ -718,9 +718,6 @@ static void hb_gt_win_Init( PHB_GT pGT, HB_FHANDLE hFilenoStdin, HB_FHANDLE hFil HB_GTSELF_SETDISPCP( pGT, NULL, NULL, FALSE ); HB_GTSELF_SETKEYCP( pGT, NULL, NULL ); - /* Add Ctrl+Break handler [vszakats] */ - SetConsoleCtrlHandler( hb_gt_win_CtrlHandler, TRUE ); - #ifndef HB_NO_ALLOC_CONSOLE /* * This is a hack for MSYS console. It does not support full screen output @@ -759,6 +756,11 @@ static void hb_gt_win_Init( PHB_GT pGT, HB_FHANDLE hFilenoStdin, HB_FHANDLE hFil hb_errInternal( 10001, "Can't allocate console", NULL, NULL ); } + /* AllocConsole() initializes standard input, standard output, + and standard error handles for the new console. [jarabal] */ + /* Add Ctrl+Break handler [vszakats] */ + SetConsoleCtrlHandler( hb_gt_win_CtrlHandler, TRUE ); + HB_GTSUPER_INIT( pGT, hFilenoStdin, hFilenoStdout, hFilenoStderr ); s_HOutput = CreateFile( TEXT( "CONOUT$" ), /* filename */