From fb225be1717a7691f178de9fcd17d894960b7a0e Mon Sep 17 00:00:00 2001 From: Przemyslaw Czerpak Date: Tue, 20 Nov 2012 10:59:34 +0000 Subject: [PATCH] 2012-11-20 11:59 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl) * harbour/src/vm/cmdarg.c ! fixed typo in my previous commit --- harbour/ChangeLog | 4 ++++ harbour/src/vm/cmdarg.c | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 4d231985bd..333715e737 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -10,6 +10,10 @@ * Change, ! Fix, % Optimization, + Addition, - Removal, ; Comment */ +2012-11-20 11:59 UTC+0100 Przemyslaw Czerpak (druzus/at/poczta.onet.pl) + * harbour/src/vm/cmdarg.c + ! fixed typo in my previous commit + 2012-11-20 11:46 UTC+0100 Viktor Szakats (harbour syenar.net) * tests/fixcase.hb * some binaries excluded diff --git a/harbour/src/vm/cmdarg.c b/harbour/src/vm/cmdarg.c index a3448ea862..6012e4054f 100644 --- a/harbour/src/vm/cmdarg.c +++ b/harbour/src/vm/cmdarg.c @@ -195,13 +195,13 @@ void hb_winmainArgVBuild( void ) iArgC = 1; lpArgV = ( LPTSTR * ) HeapAlloc( hHeap, 0, iArgC * sizeof( LPTSTR ) + - nSize * sizeof( TCHAR ) ); + nModuleName * sizeof( TCHAR ) ); lpArgV[ 0 ] = ( LPTSTR ) ( lpArgV + iArgC ); } else iArgC = 0; } - if( iArgC > 0 && nModuleName ) + if( iArgC > 0 && nModuleName != 0 ) { /* NOTE: Manually setup the executable name in Windows, because in console apps the name may be truncated