2008-08-26 02:43 UTC+0200 Viktor Szakats (harbour.01 syenar hu)

* contrib/xhb/hbcrypt.c
   * contrib/hbw32/tprinter.c
   * contrib/hbw32/w32_ole.c
   * contrib/hbw32/w32_prn.c
   * contrib/hbfbird/tests/testapi.c
   * contrib/hbziparch/hbziparc.c
   * contrib/hbziparch/hbzipnew.cpp
   * contrib/hbhpdf/harupdf.c
   * contrib/hbfimage/fi_winfu.c
   * contrib/hbfimage/fi_wrp.c
   * contrib/hbgf/hbgfw32/win32.c
   * contrib/hbgf/hbgfos2/os2pm.c
   * source/rtl/filesys.c
   * utils/hbtest/rt_miscc.c
     * // -> ANSI comments.
     ; NOTE: hbwhat32 and gtwvg remain with //.
This commit is contained in:
Viktor Szakats
2008-08-26 00:45:47 +00:00
parent 4e4a523edf
commit fae2a5f489
15 changed files with 1506 additions and 1495 deletions

View File

@@ -8,6 +8,24 @@
2008-12-31 13:59 UTC+0100 Foo Bar (foo.bar foobar.org)
*/
2008-08-26 02:43 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* contrib/xhb/hbcrypt.c
* contrib/hbw32/tprinter.c
* contrib/hbw32/w32_ole.c
* contrib/hbw32/w32_prn.c
* contrib/hbfbird/tests/testapi.c
* contrib/hbziparch/hbziparc.c
* contrib/hbziparch/hbzipnew.cpp
* contrib/hbhpdf/harupdf.c
* contrib/hbfimage/fi_winfu.c
* contrib/hbfimage/fi_wrp.c
* contrib/hbgf/hbgfw32/win32.c
* contrib/hbgf/hbgfos2/os2pm.c
* source/rtl/filesys.c
* utils/hbtest/rt_miscc.c
* // -> ANSI comments.
; NOTE: hbwhat32 and gtwvg remain with //.
2008-08-26 00:43 UTC+0200 Viktor Szakats (harbour.01 syenar hu)
* make_vc.bat
* make_vcce.bat

View File

@@ -105,24 +105,24 @@ int query( char *sel_str )
if ( isc_start_transaction ( status, &trans, 1, &db, 0, NULL ) )
ERREXIT(status, 1);
// Allocate an output SQLDA. Just to check number of columns
/* Allocate an output SQLDA. Just to check number of columns */
sqlda = ( XSQLDA * ) malloc( XSQLDA_LENGTH ( 1 ) );
sqlda->sqln = 1;
sqlda->version = 1;
// Allocate a statement
/* Allocate a statement */
if (isc_dsql_allocate_statement(status, &db, &stmt))
ERREXIT(status, 1);
// Prepare the statement.
/* Prepare the statement. */
if (isc_dsql_prepare(status, &trans, &stmt, 0, sel_str, dialect, sqlda))
ERREXIT(status, 1);
// Describe sql contents
/* Describe sql contents */
if (isc_dsql_describe(status, &stmt, dialect, sqlda))
ERREXIT(status, 1);
// Relocate necessary number of columns
/* Relocate necessary number of columns */
if ( sqlda->sqld > sqlda->sqln ) {
free( sqlda );
n = sqlda->sqld;
@@ -158,7 +158,7 @@ int query( char *sel_str )
}
if ( !sqlda->sqld ) {
// Execute and commit non-select querys
/* Execute and commit non-select querys */
if ( isc_dsql_execute ( status, &trans, &stmt, dialect, NULL ) )
ERREXIT(status, 1);

View File

@@ -73,12 +73,12 @@
#include "FreeImage.h"
// --------------------------------------------------------------------------
// Convert from FreeImage to HBITMAP ----------------------------------------
// --------------------------------------------------------------------------
/* -------------------------------------------------------------------------- */
/* Convert from FreeImage to HBITMAP ---------------------------------------- */
/* -------------------------------------------------------------------------- */
#if ( defined(HB_OS_WIN_32) || defined(__WIN32__) )
// implementation: HBITMAP bitmap = FI_FiToBitmap( FIBITMAP *dib );
/* implementation: HBITMAP bitmap = FI_FiToBitmap( FIBITMAP *dib ); */
HB_FUNC( FI_FITOBITMAP )
{
if ( hb_pcount() == 1 &&
@@ -108,7 +108,7 @@ HB_FUNC( FI_FITOBITMAP )
}
else
{
// Parameter error
/* Parameter error */
{
hb_errRT_BASE_SubstR( EG_ARG, 0, NULL,
HB_ERR_FUNCNAME, 1,
@@ -118,13 +118,13 @@ HB_FUNC( FI_FITOBITMAP )
}
}
// --------------------------------------------------------------------------
/* -------------------------------------------------------------------------- */
// --------------------------------------------------------------------------
// Convert from HBITMAP to FreeImage ----------------------------------------
// --------------------------------------------------------------------------
/* -------------------------------------------------------------------------- */
/* Convert from HBITMAP to FreeImage ---------------------------------------- */
/* -------------------------------------------------------------------------- */
// implementation: FIBITMAP *dib = FI_BitmapToFi( HBITMAP bitmap );
/* implementation: FIBITMAP *dib = FI_BitmapToFi( HBITMAP bitmap ); */
HB_FUNC( FI_BITMAPTOFI )
{
if ( hb_pcount() == 1 &&
@@ -161,7 +161,7 @@ HB_FUNC( FI_BITMAPTOFI )
}
else
{
// Parameter error
/* Parameter error */
{
hb_errRT_BASE_SubstR( EG_ARG, 0, NULL,
HB_ERR_FUNCNAME, 1,
@@ -171,13 +171,13 @@ HB_FUNC( FI_BITMAPTOFI )
}
}
// --------------------------------------------------------------------------
/* -------------------------------------------------------------------------- */
// --------------------------------------------------------------------------
// Draw an image in a window Box --------------------------------------------
// --------------------------------------------------------------------------
/* -------------------------------------------------------------------------- */
/* Draw an image in a window Box -------------------------------------------- */
/* -------------------------------------------------------------------------- */
// implementation: int scanlines = FI_WinDraw( FIBITMAP *dib, HDC hDC, nTop, nLeft, nBottom, nRight );
/* implementation: int scanlines = FI_WinDraw( FIBITMAP *dib, HDC hDC, nTop, nLeft, nBottom, nRight ); */
HB_FUNC( FI_WINDRAW )
{
if ( hb_pcount() == 6 &&
@@ -219,7 +219,7 @@ HB_FUNC( FI_WINDRAW )
}
else
{
// Parameter error
/* Parameter error */
{
hb_errRT_BASE_SubstR( EG_ARG, 0, NULL,
HB_ERR_FUNCNAME, 6,
@@ -231,6 +231,6 @@ HB_FUNC( FI_WINDRAW )
}
}
// --------------------------------------------------------------------------
/* -------------------------------------------------------------------------- */
#endif // ( defined(HB_OS_WIN_32) || defined(__WIN32__) )
#endif /* ( defined(HB_OS_WIN_32) || defined(__WIN32__) ) */

File diff suppressed because it is too large Load Diff

View File

@@ -239,9 +239,9 @@ HB_FUNC( WINADDMENUITEM )
}
// Given an id of a menuitem changes it to a MIS_SUBMENU type of menu item
// NOTE: You have to delete and reinsert a menu item if you want to change it from
// a MIS_TEXT to a MIS_SUBMENU type of menuitem
/* Given an id of a menuitem changes it to a MIS_SUBMENU type of menu item
NOTE: You have to delete and reinsert a menu item if you want to change it from
a MIS_TEXT to a MIS_SUBMENU type of menuitem */
HB_FUNC( WINMAKESUBMENUITEM )
{
MENUITEM mit;
@@ -256,7 +256,7 @@ HB_FUNC( WINMAKESUBMENUITEM )
mit.hwndSubMenu = hb_parnl(3);
mit.afStyle |= MIS_SUBMENU;
// re-insert the menuitem
/* re-insert the menuitem */
WinSendMsg((HWND) hb_parnl(1), MM_INSERTITEM, &mit, &text);
}
hb_retnl(0);
@@ -309,10 +309,10 @@ HB_FUNC( WINSETWIDTH )
HB_FUNC( SENDMESSAGE )
{
hb_retnl( (LONG) WinSendMsg(
(HWND) hb_parnl( 1 ), // handle of destination window
(ULONG) hb_parnl( 2 ), // message to send
(MPARAM) hb_parnl( 3 ), // first message parameter
(MPARAM) hb_parnl( 4 ) // second message parameter
(HWND) hb_parnl( 1 ), /* handle of destination window */
(ULONG) hb_parnl( 2 ), /* message to send */
(MPARAM) hb_parnl( 3 ), /* first message parameter */
(MPARAM) hb_parnl( 4 ) /* second message parameter */
) );
}
@@ -401,7 +401,7 @@ HB_FUNC( WINSETLEFT )
HB_FUNC( POSTQUITMESSAGE )
{
WinPostMsg((HWND) hb_parnl( 1 ), WM_QUIT, 0L, 0L);
//PostQuitMessage( hb_parnl( 1 ) );
/*PostQuitMessage( hb_parnl( 1 ) );*/
}

View File

@@ -67,7 +67,7 @@ HB_FUNC( WINREGISTERCLASS )
LPTSTR lpszClassName = HB_TCHAR_CONVTO( hb_parcx( 1 ) );
wndclass.lpszClassName = lpszClassName;
wndclass.style = CS_OWNDC | CS_VREDRAW | CS_HREDRAW; // hb_parnl( 2 );
wndclass.style = CS_OWNDC | CS_VREDRAW | CS_HREDRAW; /* hb_parnl( 2 ); */
wndclass.cbClsExtra = hb_parnl( 3 );
wndclass.cbWndExtra = 0;
wndclass.lpfnWndProc = WndProc;
@@ -222,10 +222,10 @@ HB_FUNC( SETMENU )
HB_FUNC( SENDMESSAGE )
{
hb_retnl( (LONG) SendMessage(
(HWND) hb_parptr( 1 ), // handle of destination window
(UINT) hb_parni( 2 ), // message to send
(WPARAM) hb_parnl( 3 ), // first message parameter
(LPARAM) hb_parnl( 4 ) // second message parameter
(HWND) hb_parptr( 1 ), /* handle of destination window */
(UINT) hb_parni( 2 ), /* message to send */
(WPARAM) hb_parnl( 3 ), /* first message parameter */
(LPARAM) hb_parnl( 4 ) /* second message parameter */
) );
}

File diff suppressed because it is too large Load Diff

View File

@@ -94,9 +94,9 @@ BOOL hb_PrinterExists( LPSTR pPrinterName )
if( !strchr( pPrinterName, HB_OS_PATH_LIST_SEP_CHR ) && !hb_isLegacyDevice( pPrinterName ) )
{ // Don't bother with test if '\' in string
{ /* Don't bother with test if '\' in string */
if( hb_iswinnt() )
{ // Use EnumPrinter() here because much faster than OpenPrinter()
{ /* Use EnumPrinter() here because much faster than OpenPrinter() */
EnumPrinters( Flags, NULL, 4, ( LPBYTE ) NULL, 0, &needed, &returned );
if( needed > 0 )
{
@@ -151,7 +151,7 @@ BOOL hb_GetDefaultPrinter( char * pPrinterName, LPDWORD pdwBufferSize )
if( osvi.dwPlatformId == VER_PLATFORM_WIN32_NT && osvi.dwMajorVersion >= 5 ) /* Windows 2000 or later */
{
typedef BOOL( WINAPI * DEFPRINTER ) ( LPSTR, LPDWORD ); // stops warnings
typedef BOOL( WINAPI * DEFPRINTER ) ( LPSTR, LPDWORD ); /* stops warnings */
DEFPRINTER fnGetDefaultPrinter;
HMODULE hWinSpool = LoadLibrary( TEXT( "winspool.drv" ) );
@@ -349,7 +349,7 @@ LONG hb_PrintFileRaw( UCHAR * cPrinterName, UCHAR * cFileName, UCHAR * cDocName
{
if( printBuffer[nRead - 1] == 26 )
{
nRead--; // Skip the EOF() character
nRead--; /* Skip the EOF() character */
}
WritePrinter( hPrinter, printBuffer, nRead, &nWritten );
}
@@ -554,7 +554,7 @@ HB_FUNC( GETPRINTERS )
}
else
{
// Tony (ABC) 11/1/2005 1:40PM.
/* Tony (ABC) 11/1/2005 1:40PM. */
for( a = 0; a < returned; a++, pPrinterEnum++ )
{
if( !bLocalPrintersOnly
@@ -618,31 +618,33 @@ HB_FUNC( GETPRINTERS )
CloseHandle( hPrinter );
}
}
// Tony (ABC) 11/1/2005 1:40PM. Old Code... Justo in case.
// hb_arrayNew( SubItems, 0 );
// hb_itemPutC( File, pPrinterEnum->pPrinterName );
// hb_itemPutC( Port, pPrinterEnum->pPortName );
/* Tony (ABC) 11/1/2005 1:40PM. Old Code... Justo in case. */
#if 0
hb_arrayNew( SubItems, 0 );
hb_itemPutC( File, pPrinterEnum->pPrinterName );
hb_itemPutC( Port, pPrinterEnum->pPortName );
if ( pPrinterEnum->Attributes & PRINTER_ATTRIBUTE_LOCAL)
{
hb_itemPutC( Net,"LOCAL" );
}
else
{
if ( pPrinterEnum->Attributes & PRINTER_ATTRIBUTE_NETWORK)
{
hb_itemPutC( Net,"NETWORK" );
}
else
{
hb_itemPutC( Net, "ERROR" );
}
}
// if ( pPrinterEnum->Attributes & PRINTER_ATTRIBUTE_LOCAL)
// {
// hb_itemPutC( Net,"LOCAL" );
// }
// else
// {
// if ( pPrinterEnum->Attributes & PRINTER_ATTRIBUTE_NETWORK)
// {
// hb_itemPutC( Net,"NETWORK" );
// }
// else
// {
// hb_itemPutC( Net, "ERROR" );
// }
// }
// hb_arrayAddForward( SubItems , File ) ;
// hb_arrayAddForward( SubItems , Port ) ;
// hb_arrayAddForward( SubItems, Net ) ;
// hb_arrayAddForward( ArrayPrinter , SubItems );
hb_arrayAddForward( SubItems , File ) ;
hb_arrayAddForward( SubItems , Port ) ;
hb_arrayAddForward( SubItems, Net ) ;
hb_arrayAddForward( ArrayPrinter , SubItems );
#endif
}
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -201,7 +201,7 @@ HB_FUNC( WIN32_DELETEDC )
* phDC = NULL;
}
hb_retni( 0 ); // Return zero as a new handle even if fails
hb_retni( 0 ); /* Return zero as a new handle even if fails */
}
HB_FUNC( WIN32_STARTPAGE )
@@ -263,8 +263,8 @@ HB_FUNC( WIN32_TEXTOUT )
}
else if( TextOut( hDC, iRow, iCol, lpData, iLen ) )
{
GetTextExtentPoint32( hDC, lpData, iLen, &sSize ); // Get the length of the text in device size
Result = ( LONG ) sSize.cx; // return the width so we can update the current pen position (::PosY)
GetTextExtentPoint32( hDC, lpData, iLen, &sSize ); /* Get the length of the text in device size */
Result = ( LONG ) sSize.cx; /* return the width so we can update the current pen position (::PosY) */
}
HB_TCHAR_FREE( lpData );
@@ -291,12 +291,12 @@ HB_FUNC( WIN32_GETTEXTSIZE )
lpData = HB_TCHAR_CONVNTO( hb_parc( 2 ), iLen );
GetTextExtentPoint32( hDC, lpData, iLen, &sSize ); // Get the length of the text in device size
GetTextExtentPoint32( hDC, lpData, iLen, &sSize ); /* Get the length of the text in device size */
if( ISLOG( 4 ) && !hb_parl( 4 ) )
Result = ( LONG ) sSize.cy; // return the height
Result = ( LONG ) sSize.cy; /* return the height */
else
Result = ( LONG ) sSize.cx; // return the width
Result = ( LONG ) sSize.cx; /* return the width */
HB_TCHAR_FREE( lpData );
}
@@ -364,7 +364,7 @@ HB_FUNC( WIN32_CREATEFONT )
if( iDiv )
iWidth = MulDiv( abs( iMul ), GetDeviceCaps( hDC, LOGPIXELSX ), abs( iDiv ) );
else
iWidth = 0; // Use the default font width
iWidth = 0; /* Use the default font width */
hFont = CreateFont( iHeight, iWidth, 0, 0, iWeight, dwItalic, dwUnderLine, 0,
dwCharSet, OUT_DEVICE_PRECIS, CLIP_DEFAULT_PRECIS, DRAFT_QUALITY,
@@ -431,7 +431,7 @@ HB_FUNC( WIN32_SETDOCUMENTPROPERTIES )
{
DocumentProperties( 0, hPrinter, lpPrinterName, pDevMode, pDevMode, DM_OUT_BUFFER );
if( ISNUM( 3 ) && hb_parnl( 3 ) ) // 22/02/2007 don't change if 0
if( ISNUM( 3 ) && hb_parnl( 3 ) ) /* 22/02/2007 don't change if 0 */
pDevMode->dmPaperSize = ( short ) hb_parnl( 3 );
if( ISLOG( 4 ) )
@@ -440,13 +440,13 @@ HB_FUNC( WIN32_SETDOCUMENTPROPERTIES )
if( ISNUM( 5 ) && hb_parnl( 5 ) > 0 )
pDevMode->dmCopies = ( short ) hb_parnl( 5 );
if( ISNUM( 6 ) && hb_parnl( 6 ) ) // 22/02/2007 don't change if 0
if( ISNUM( 6 ) && hb_parnl( 6 ) ) /* 22/02/2007 don't change if 0 */
pDevMode->dmDefaultSource = ( short ) hb_parnl( 6 );
if( ISNUM( 7 ) && hb_parnl( 7 ) ) // 22/02/2007 don't change if 0
if( ISNUM( 7 ) && hb_parnl( 7 ) ) /* 22/02/2007 don't change if 0 */
pDevMode->dmDuplex = ( short ) hb_parnl( 7 );
if( ISNUM( 8 ) && hb_parnl( 8 ) ) // 22/02/2007 don't change if 0
if( ISNUM( 8 ) && hb_parnl( 8 ) ) /* 22/02/2007 don't change if 0 */
pDevMode->dmPrintQuality = ( short ) hb_parnl( 8 );
Result = ( ResetDC( hDC, pDevMode ) != NULL );
@@ -465,7 +465,7 @@ HB_FUNC( WIN32_SETDOCUMENTPROPERTIES )
hb_retl( Result );
}
// Functions for Loading & Printing bitmaps
/* Functions for Loading & Printing bitmaps */
HB_FUNC( WIN32_LOADBITMAPFILE )
{
@@ -482,14 +482,14 @@ HB_FUNC( WIN32_LOADBITMAPFILE )
{
dwFileSize = GetFileSize( hFile, &dwHighSize );
if( ( dwFileSize != INVALID_FILE_SIZE ) && !dwHighSize ) // Do not continue if File size error or TOO big for memory
if( ( dwFileSize != INVALID_FILE_SIZE ) && !dwHighSize ) /* Do not continue if File size error or TOO big for memory */
{
pbmfh = ( BITMAPFILEHEADER * ) hb_xgrab( dwFileSize );
if( pbmfh )
{
bSuccess = ReadFile( hFile, pbmfh, dwFileSize, &dwBytesRead, NULL );
bSuccess = bSuccess && ( dwBytesRead == dwFileSize ) && ( pbmfh->bfType == *( WORD * ) "BM" ); //&& (pbmfh->bfSize == dwFileSize) ;
bSuccess = bSuccess && ( dwBytesRead == dwFileSize ) && ( pbmfh->bfType == *( WORD * ) "BM" ); /*&& (pbmfh->bfSize == dwFileSize) ;*/
}
}
@@ -498,7 +498,7 @@ HB_FUNC( WIN32_LOADBITMAPFILE )
if( bSuccess )
{
hb_retclen( ( char * ) pbmfh, dwFileSize ); // hb_retclenAdoptRaw
hb_retclen( ( char * ) pbmfh, dwFileSize ); /* hb_retclenAdoptRaw */
if( pbmfh )
hb_xfree( pbmfh );
@@ -524,7 +524,7 @@ HB_FUNC( WIN32_DRAWBITMAP )
pBits = ( BYTE * ) pbmfh + pbmfh->bfOffBits;
if( pbmi->bmiHeader.biSize == sizeof( BITMAPCOREHEADER ) )
{ // Remember there are 2 types of BitMap File
{ /* Remember there are 2 types of BitMap File */
cxDib = ( ( BITMAPCOREHEADER * ) pbmi )->bcWidth;
cyDib = ( ( BITMAPCOREHEADER * ) pbmi )->bcHeight;
}
@@ -604,9 +604,9 @@ HB_FUNC( WIN32_SETPEN )
void ** phPEN = ( void ** ) hb_gcAlloc( sizeof( HPEN * ), win32_HPEN_release );
* phPEN = ( void * ) CreatePen( hb_parni( 2 ), // pen style
hb_parni( 3 ), // pen width
( COLORREF ) hb_parnl( 4 ) // pen color
* phPEN = ( void * ) CreatePen( hb_parni( 2 ), /* pen style */
hb_parni( 3 ), /* pen width */
( COLORREF ) hb_parnl( 4 ) /* pen color */
);
hOldPen = ( HPEN ) SelectObject( hDC, ( HPEN ) * phPEN );

View File

@@ -1105,7 +1105,7 @@ HB_FUNC( HB_UNZIPFILE )
}
else
{
//s.r. change "*.*" to "*" because file without extension were ignored
/* s.r. change "*.*" to "*" because file without extension were ignored */
UnzipCreateArray( (char*) "*", 1 );
}

View File

@@ -142,8 +142,8 @@ static int hb_CheckSpanMode( char * szFile )
try
{
// s.r. to avoid GPF when ZIP file is read only !
// szZip.Open( szFile, CZipArchive::zipOpen, 0 );
/* s.r. to avoid GPF when ZIP file is read only ! */
/* szZip.Open( szFile, CZipArchive::zipOpen, 0 ); */
szZip.Open( szFile, hbza_pZipI.iReadOnly ? CZipArchive::zipOpenReadOnly : CZipArchive::zipOpen, 0 );
}
catch( CZipException &e )
@@ -637,7 +637,7 @@ int hb_DeleteSel( char *szFile, PHB_ITEM pArray, BOOL bCase )
case -1:
case -2:
// default:
/* default: */
iReturn = false;
}
}
@@ -766,12 +766,12 @@ int hb_UnzipSel( char *szFile, PHB_ITEM pBlock, BOOL lWithPath, char *szPassWord
/* TODO: They're both the same.... */
if( !HB_IS_BLOCK( pProgress ) )
{
// szZip.SetPassword( szPassWord );
/* szZip.SetPassword( szPassWord ); */
szZip.ExtractFile( ( WORD ) ulCount, ( LPCTSTR ) szPath, bWithPath, NULL, 65536 );
}
else
{
// szZip.SetPassword( szPassWord );
/* szZip.SetPassword( szPassWord ); */
szZip.ExtractFile( ( WORD )ulCount, ( LPCTSTR )szPath, bWithPath, NULL, 65536 );
}
}
@@ -953,12 +953,12 @@ int hb_UnzipSelIndex( char *szFile, PHB_ITEM pBlock, BOOL lWithPath, char *szPas
/* TODO: They're both the same.... */
if( !HB_IS_BLOCK( pProgress ) )
{
// szZip.SetPassword( szPassWord );
/* szZip.SetPassword( szPassWord ); */
szZip.ExtractFile( ( WORD )ulCount, ( LPCTSTR )szPath, bWithPath, NULL, 65536 );
}
else
{
// szZip.SetPassword( szPassWord );
/* szZip.SetPassword( szPassWord ); */
szZip.ExtractFile( ( WORD )ulCount, ( LPCTSTR )szPath, bWithPath, NULL, 65536 );
}
}
@@ -997,7 +997,7 @@ BOOL hb_TransferFilesFromzip( char *szSource, char *szDest, PHB_ITEM pArray )
case -1:
case -2:
// default:
/* default: */
bReturn = FALSE;
}
}
@@ -1014,7 +1014,7 @@ BOOL hb_TransferFilesFromzip( char *szSource, char *szDest, PHB_ITEM pArray )
case -1:
case -2:
// default:
/* default: */
bReturn1 = FALSE;
}
}
@@ -1046,7 +1046,7 @@ int hb_UnzipAll(char *szFile,PHB_ITEM pBlock, BOOL bWithPath,char *szPassWord,ch
{
bool iReturn = true;
uLong uiCount = 0;
// int iCause = 0;
/* int iCause = 0; */
int iMode;
CZipArchive szZip;
BOOL bChange = FALSE;
@@ -1094,7 +1094,7 @@ int hb_UnzipAll(char *szFile,PHB_ITEM pBlock, BOOL bWithPath,char *szPassWord,ch
catch( CZipException &e )
{
HB_SYMBOL_UNUSED( e );
// iCause = e.m_iCause;
/* iCause = e.m_iCause; */
}
if( iReturn )
@@ -1159,13 +1159,13 @@ int hb_UnzipAll(char *szFile,PHB_ITEM pBlock, BOOL bWithPath,char *szPassWord,ch
{
szZip.CloseFile( NULL, true );
HB_SYMBOL_UNUSED( e );
// iCause = e.m_iCause;
/* iCause = e.m_iCause; */
}
if( bChange )
{
bChange = FALSE;
// szPath = NULL;
/* szPath = NULL; */
}
}
}
@@ -1323,7 +1323,7 @@ int hb_CmpTdSpan( char *szFile, PHB_ITEM pArray, int iCompLevel, PHB_ITEM pBlock
catch( ... )
{}
//if( ! bReturn )
/*if( ! bReturn )*/
{
if( szPassWord != NULL )
szZip.SetPassword( szPassWord );

View File

@@ -90,9 +90,9 @@ void nxs_crypt(
keylen = NXS_MAX_KEYLEN;
}
// debug
//memcpy( cipher, source, srclen );
// end debug
#ifdef DEBUG_0
memcpy( cipher, source, srclen );
#endif
/* pass one: scramble the source using the key */
nxs_scramble( source, srclen, key, keylen, cipher );
@@ -157,9 +157,6 @@ void nxs_scramble(
len = (srclen / keylen) * keylen;
nxs_partial_scramble( source, cipher, scramble, len, keylen );
// last pos was not done.
//memcpy( cipher +len , source + len , srclen - len );
keylen = srclen - len;
nxs_make_scramble( scramble, key, keylen );
nxs_partial_scramble( source + len, cipher + len, scramble, keylen, keylen );
@@ -288,7 +285,7 @@ void nxs_xordecode(
USHORT keypos = 0;
BYTE c_bitrest, c_bitleft;
// A very short block?
/* A very short block? */
if ( keylen > cipherlen - pos )
{
keylen = ( USHORT ) ( cipherlen - pos);
@@ -310,7 +307,7 @@ void nxs_xordecode(
if (keypos == (USHORT) keylen )
{
keypos = 0;
// last block
/* last block */
if ( keylen > cipherlen - pos )
{
keylen = ( USHORT ) (cipherlen - pos);

View File

@@ -2531,19 +2531,19 @@ HB_EXPORT HB_FHANDLE hb_fsExtOpen( BYTE * pFilename, BYTE * pDefExt,
HB_TRACE(HB_TR_DEBUG, ("hb_fsExtOpen(%s, %s, %hu, %p, %p)", pFilename, pDefExt, uiExFlags, pPaths, pError));
/*
#define FXO_TRUNCATE 0x0100 // Create (truncate if exists)
#define FXO_APPEND 0x0200 // Create (append if exists)
#define FXO_UNIQUE 0x0400 // Create unique file FO_EXCL ???
#define FXO_FORCEEXT 0x0800 // Force default extension
#define FXO_DEFAULTS 0x1000 // Use SET command defaults
#define FXO_DEVICERAW 0x2000 // Open devices in raw mode
// xHarbour extension
#define FXO_SHARELOCK 0x4000 // emulate DOS SH_DENY* mode in POSIX OS
#define FXO_COPYNAME 0x8000 // copy final szPath into pFilename
#if 0
#define FXO_TRUNCATE 0x0100 /* Create (truncate if exists) */
#define FXO_APPEND 0x0200 /* Create (append if exists) */
#define FXO_UNIQUE 0x0400 /* Create unique file FO_EXCL ??? */
#define FXO_FORCEEXT 0x0800 /* Force default extension */
#define FXO_DEFAULTS 0x1000 /* Use SET command defaults */
#define FXO_DEVICERAW 0x2000 /* Open devices in raw mode */
/* xHarbour extension */
#define FXO_SHARELOCK 0x4000 /* emulate DOS SH_DENY* mode in POSIX OS */
#define FXO_COPYNAME 0x8000 /* copy final szPath into pFilename */
hb_errGetFileName( pError );
*/
#endif
szPath = ( BYTE * ) hb_xgrab( _POSIX_PATH_MAX + 1 );

View File

@@ -67,7 +67,7 @@ RT_FUNDEF( R_PASSENLC )
CLIPPER HB_STOD( void )
{
// The length check is a fix to avoid buggy behaviour of _retds()
/* The length check is a fix to avoid buggy behaviour of _retds() */
_retds( ( ISCHAR( 1 ) && _parclen( 1 ) == 8 ) ? _parc( 1 ) : " " );
}