diff --git a/harbour/ChangeLog b/harbour/ChangeLog index d53bf035cb..004c9a1f16 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -1,3 +1,29 @@ +2000-08-15 02:48 UTC+0100 Victor Szakats + + ; Waiting for some minor patches before the new release. + + * source/common/hbver.c + + QUESTION: added about bit depth detection. + + * doc/whatsnew.txt + + Few new items added. + + * doc/en/cmdline.txt + + Missing part added. + + * source/lang/msgko.c + * tests/keywords.prg + * samples/pe/editorhi.prg + ! Tabs removed. + + * source/vm/mainwin.c + * Some formatting. + * Fixed form MSVC + + * contrib/rdd_ads/ads1.c + * contrib/rdd_ads/adsfunc.c + ! Fixed for MSVC + 2000-08-14 14:45 UTC-0400 David G. Holm * contrib/rdd_ads/ace.h diff --git a/harbour/contrib/rdd_ads/ads1.c b/harbour/contrib/rdd_ads/ads1.c index 3e507d8c8f..51b2775baa 100644 --- a/harbour/contrib/rdd_ads/ads1.c +++ b/harbour/contrib/rdd_ads/ads1.c @@ -206,7 +206,7 @@ static ERRCODE hb_adsCheckBofEof( ADSAREAP pArea ) return SUPER_SKIPFILTER( (AREAP)pArea, 1 ); } -static BOOL strcmpNoCase( char* s1, char* s2, int n ) +static BOOL strcmpNoCase( char * s1, char * s2, int n ) { int i = 0; while( *s1 && *s2 && ( !n || i++ < n ) ) @@ -1012,9 +1012,9 @@ static ERRCODE adsOrderCreate( ADSAREAP pArea, LPDBORDERCREATEINFO pOrderInfo ) else { int slen = strlen( pArea->lpDataInfo->szFileName ); - char *ptr = pArea->lpDataInfo->szFileName + slen - 4; - if( strcmpNoCase( pOrderInfo->abBagName, pArea->lpDataInfo->szFileName, - ( slen >= 4 && strcmpNoCase( ".dbf",ptr,0 ) )? slen-4:0 ) ) + char * ptr = pArea->lpDataInfo->szFileName + slen - 4; + if( strcmpNoCase( ( char * ) pOrderInfo->abBagName, ( char * ) pArea->lpDataInfo->szFileName, + ( slen >= 4 && strcmpNoCase( ".dbf", ptr, 0 ) ) ? slen-4:0 ) ) ulOptions = ADS_COMPOUND; } diff --git a/harbour/contrib/rdd_ads/adsfunc.c b/harbour/contrib/rdd_ads/adsfunc.c index 79d35d773e..6019b2aac9 100644 --- a/harbour/contrib/rdd_ads/adsfunc.c +++ b/harbour/contrib/rdd_ads/adsfunc.c @@ -439,7 +439,7 @@ HB_FUNC( ADSENABLEENCRYPTION ) { ADSAREAP pArea; UNSIGNED32 ulRetVal; - char *pucPassword = hb_parc( 1 ); + char * pucPassword = hb_parc( 1 ); if( strlen( pucPassword ) == 0 ) { @@ -449,7 +449,7 @@ HB_FUNC( ADSENABLEENCRYPTION ) pArea = (ADSAREAP) hb_rddGetCurrentWorkAreaPointer(); if( pArea ) { - ulRetVal = AdsEnableEncryption( pArea->hTable,pucPassword ); + ulRetVal = AdsEnableEncryption( pArea->hTable, ( BYTE * ) pucPassword ); hb_retni( ulRetVal ); } else diff --git a/harbour/doc/en/cmdline.txt b/harbour/doc/en/cmdline.txt index 2a8af1bc06..c411aa508a 100644 --- a/harbour/doc/en/cmdline.txt +++ b/harbour/doc/en/cmdline.txt @@ -1,6 +1,7 @@ /* * $Id$ */ + /* $DOC$ * $FUNCNAME$ * Command line Utility @@ -88,6 +89,18 @@ * - The CLIPPER, HARBOUR and Harbour application command line parsing * is a different beast, see CMDARG.C for a NOTE. * + * Notes: + * + * - All occurences where a path is accepted, + * Harbour should handle the quote char to specify + * path containing space, negative sign, slash, or + * any other chars with special meaning. + * + * /i"c:/hello/" + * -i"c:/hello-n" + * /i"c:/program files/" + * -i"c:/program files/" + * * * Just some examples for the various accepted forms: * //F20 == /F20 == F20 == F:20 == F20X diff --git a/harbour/doc/whatsnew.txt b/harbour/doc/whatsnew.txt index 4a31d7ff05..3af1d1d5ba 100644 --- a/harbour/doc/whatsnew.txt +++ b/harbour/doc/whatsnew.txt @@ -4,6 +4,8 @@ ---------------------------------------------------------------------- +Version 0.35 Build 35 (2000-08-15) + - Added HB_IDLE*() idle state handling functions. - Watcom C++ fixes. - SET RELATION support for RDDADS @@ -20,6 +22,10 @@ TRANSFORM(), DISKSPACE(), CURDIR(), __GET()), HBDOC, HBTEST (for Xbase++ and Linux), Documentation, Class engine - HBZLIB enhancements +- MySQL database access contribution started +- ADS RDD encryption/decryption functions added. +- New GTCGI driver +- Improved command line parsing Version 0.34 Build 34 (2000-06-02) diff --git a/harbour/samples/pe/editorhi.prg b/harbour/samples/pe/editorhi.prg index d2efae9af8..e66b5dfe26 100644 --- a/harbour/samples/pe/editorhi.prg +++ b/harbour/samples/pe/editorhi.prg @@ -46,7 +46,7 @@ STATIC nESize:=4096 // default buffer size STATIC oEditor // static variable used to speed access to the editor STATIC aEdit:={ } // the stack of used editors -STATIC lInsert //current Insert state +STATIC lInsert //current Insert state // ** @@ -409,9 +409,9 @@ LOCAL lSaveAllowed, lSaved:=.F. ED_Config( oEditor[E_EDIT], nTop, nLeft, nBottom, nRight, 0, 0 ) DO WHILE .T. - nRow =ED_Stabilize() //displays all visible lines - // It don't uses incremantal stabilization for performance reasons - + nRow =ED_Stabilize() //displays all visible lines + // It don't uses incremantal stabilization for performance reasons + IF( nRow != ED_Row() ) nRow =ED_Row() @ oEditor[E_TOP], nState SAY STRZERO( nRow,4 ) @@ -423,7 +423,7 @@ LOCAL lSaveAllowed, lSaved:=.F. SETPOS( nTop+ED_WinRow(), nLeft+ED_WinCol() ) // nKey =WaitForKey() - nKey =INKEY(0) + nKey =INKEY(0) DO CASE CASE( nKey>=32 .AND. nKey<256 ) @@ -432,7 +432,7 @@ LOCAL lSaveAllowed, lSaved:=.F. ENDIF CASE( nKey == K_F2 .AND. lSaveAllowed ) - lSaved :=EditorSave( oEditor ) //save the copy of edited buffer + lSaved :=EditorSave( oEditor ) //save the copy of edited buffer CASE( EditorMove( nKey ) ) @@ -461,7 +461,7 @@ LOCAL lSaveAllowed, lSaved:=.F. ENDCASE ENDDO - EditorPop() //restore the proviously used editor + EditorPop() //restore the proviously used editor SetCursor( nCursor ) RESTBOX( oBox ) @@ -553,7 +553,7 @@ LOCAL lMoved:=.T. ED_End() CASE( nKey == K_CTRL_RIGHT ) -// ED_NWord() //there are some problems with it +// ED_NWord() //there are some problems with it CASE( nKey == K_CTRL_LEFT ) ED_PWord() @@ -598,7 +598,7 @@ LOCAL nHandle, cFile, cNew cFile =EditorCargo(oEdit) IF( EMPTY(cFile) ) - cFile ='TESTFILE.TXT' //GetFileName( 10, 10 ) + cFile ='TESTFILE.TXT' //GetFileName( 10, 10 ) ENDIF IF( EMPTY(cFile) ) diff --git a/harbour/source/common/hbver.c b/harbour/source/common/hbver.c index f22a438cce..c19054521d 100644 --- a/harbour/source/common/hbver.c +++ b/harbour/source/common/hbver.c @@ -160,19 +160,21 @@ char * hb_verPlatform( void ) rc = DosQuerySysInfo( 1L, QSV_MAX, ( void * ) aulQSV, sizeof( ULONG ) * QSV_MAX ); - if( rc == 0 ) { + if( rc == 0 ) + { /* is this OS/2 2.x ? */ - if (aulQSV[ QSV_VERSION_MINOR -1 ] < 30) { + if( aulQSV[ QSV_VERSION_MINOR - 1 ] < 30 ) + { sprintf( pszPlatform, "OS/2 %ld.%02ld", - aulQSV[ QSV_VERSION_MAJOR -1 ] / 10, - aulQSV[ QSV_VERSION_MINOR -1 ] ); - } else { - sprintf( pszPlatform, "OS/2 %2.2f", - (float) aulQSV[ QSV_VERSION_MINOR -1 ] / 10); + aulQSV[ QSV_VERSION_MAJOR - 1 ] / 10, + aulQSV[ QSV_VERSION_MINOR - 1 ] ); } - } else { - sprintf( pszPlatform, "OS/2" ); + else + sprintf( pszPlatform, "OS/2 %2.2f", + ( float ) aulQSV[ QSV_VERSION_MINOR - 1 ] / 10 ); } + else + sprintf( pszPlatform, "OS/2" ); } #elif defined(HB_OS_WIN_32) @@ -386,6 +388,8 @@ char * hb_verCompiler( void ) { char szSub[ 32 ]; + /* QUESTION: Is there any better, safer, more official way to detect + the bit depth of the C compiler ? [vszakats] */ sprintf( szSub, " (%i bit)", ( int ) ( sizeof( int ) * 8 ) ); strcat( pszCompiler, szSub ); } diff --git a/harbour/source/lang/msgko.c b/harbour/source/lang/msgko.c index 47e22e8e1a..939b298aa7 100644 --- a/harbour/source/lang/msgko.c +++ b/harbour/source/lang/msgko.c @@ -92,7 +92,7 @@ static HB_LANG s_lang = "Y/N", "À߸øµÈ Ç¥Çö½Ä", - /* Error description names */ + /* Error description names */ "Unknown error", "Argument error", diff --git a/harbour/source/vm/mainwin.c b/harbour/source/vm/mainwin.c index 06642cc143..8bf2858bb9 100644 --- a/harbour/source/vm/mainwin.c +++ b/harbour/source/vm/mainwin.c @@ -51,8 +51,8 @@ int WINAPI WinMain( HINSTANCE hInstance, /* handle to current instance */ LPSTR lpCmdLine, /* pointer to command line */ int iCmdShow ) /* show state of window */ { - LPSTR pArgs = LocalAlloc( LMEM_FIXED, strlen( lpCmdLine ) + 1 ), pArg = pArgs; - BYTE bAppName[ 250 ]; + LPSTR pArgs = ( LPSTR ) LocalAlloc( LMEM_FIXED, strlen( lpCmdLine ) + 1 ), pArg = pArgs; + char szAppName[ 250 ]; strcpy( pArgs, lpCmdLine ); @@ -61,23 +61,23 @@ int WINAPI WinMain( HINSTANCE hInstance, /* handle to current instance */ HB_SYMBOL_UNUSED( hPrevInstance ); HB_SYMBOL_UNUSED( iCmdShow ); - GetModuleFileName( hInstance, bAppName, 249 ); - argv[ 0 ] = bAppName; + GetModuleFileName( hInstance, szAppName, 249 ); + argv[ 0 ] = szAppName; if( * pArgs != 0 ) argv[ ++argc ] = pArgs; - while( * pArg != 0 ) + while( *pArg != 0 ) { - if( * pArg == ' ' ) + if( *pArg == ' ' ) { - * pArg++ = 0; + *pArg++ = 0; argc++; - while( * pArg == ' ' ) - pArg++; + while( *pArg == ' ' ) + pArg++; - if( * pArg != 0 ) + if( *pArg != 0 ) argv[ argc ] = pArg++; else argc--; diff --git a/harbour/tests/keywords.prg b/harbour/tests/keywords.prg index 466a0f4a23..43d1ca8e24 100644 --- a/harbour/tests/keywords.prg +++ b/harbour/tests/keywords.prg @@ -24,13 +24,13 @@ Function Main() // // -// NEXT(nExt) //in Clipper: NEXT does not match FOR +// NEXT(nExt) //in Clipper: NEXT does not match FOR // BEGIN( bEgin +';' + ;; //////Clipper doesn't like more then one ';' // ";" ; /* ;;;;;Clipper doesn't like this comment after ';' ;;;;;;; */ // ) BREAK_(bReak) -// CASE(case) //it is not possible to call case() in this context - case :=CASE( CASE ) //this is valid +// CASE(case) //it is not possible to call case() in this context + case :=CASE( CASE ) //this is valid //DO is reserved function name in Clipper! DO( nExt+bEgin/bReak-do*wHile%cAse $ wIth ) @@ -100,9 +100,9 @@ Local nExt, nExt7, nExtNEXT //nExt++ // TODO: PP steals the ++ in Clipper: NEXT does not match FOR nExt :=nExt++ - --nExt /*next*/ + --nExt /*next*/ nExt7 :=7 - nExtNEXT := nExt //next + nExtNEXT := nExt //next //nExt[ 1 ] :=nExt // TODO: PP steals the [... in Clipper: NEXT does not match FOR //nExt[ nExt ] := next[ next ] @@ -169,7 +169,7 @@ LOCAL bReak:=0 IF( bReak = 0 ) Break /*break*/ ( nil ) BREAK /* break to beggining */ - Break(0) //in Clipper: syntax error: ')' + Break(0) //in Clipper: syntax error: ')' ENDIF Break /*** break ***/ ; @@ -191,7 +191,7 @@ LOCAL bReak:=0 ; //it ; //often? ;/////////////////////////////////////////////////// - (0) //in Clipper: incomplete statement or unbalanced delimiters + (0) //in Clipper: incomplete statement or unbalanced delimiters begin sequence FOR bReak:=1 To 10 @@ -483,7 +483,7 @@ EXIT FUNCTION EXIT( exit ) exit() exit( exit ) -// EXIT //EXIT statement with no loop in sight +// EXIT //EXIT statement with no loop in sight FOR exit:=1 TO 10 exit++ @@ -498,7 +498,7 @@ EXIT FUNCTION EXIT( exit ) DO CASE CASE exit -// EXIT //EXIT statement with no loop in sight +// EXIT //EXIT statement with no loop in sight CASE !exit exit() ENDCASE