From 83ea866c61ffb64ec1b02803b1f073db80eb18c5 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Thu, 14 Jan 2010 02:26:19 +0000 Subject: [PATCH] 2010-01-14 03:22 UTC+0100 Viktor Szakats (harbour.01 syenar.hu) * contrib/hbwin/win_prn3.c * ULONG -> HB_SIZE ! Fixed new warning in hb_tstrncat() (assigment in conditional). I've now basically restored my original version taken from common lib. * contrib/hbwin/mapi.c * Formatting. --- harbour/ChangeLog | 13 +++++++++++-- harbour/contrib/hbwin/mapi.c | 2 +- harbour/contrib/hbwin/win_prn3.c | 23 ++++++++++++----------- 3 files changed, 24 insertions(+), 14 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 7b9aad74a8..f0ff9df643 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -17,13 +17,22 @@ past entries belonging to author(s): Viktor Szakats. */ +2010-01-14 03:22 UTC+0100 Viktor Szakats (harbour.01 syenar.hu) + * contrib/hbwin/win_prn3.c + * ULONG -> HB_SIZE + ! Fixed new warning in hb_tstrncat() (assigment in conditional). + I've now basically restored my original version taken from common lib. + + * contrib/hbwin/mapi.c + * Formatting. + 2010-01-13 18:19 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com) * contrib/hbide/ideeditor.prg * contrib/hbide/idemisc.prg * contrib/hbide/ideobject.prg * contrib/hbide/idesources.prg - + Implemented line numbers in editing objects. - I used a very simplified way to achieve which + + Implemented line numbers in editing objects. + I used a very simplified way to achieve which otherwise is implemented in altogether different ways in Qt examples scattered over the net. diff --git a/harbour/contrib/hbwin/mapi.c b/harbour/contrib/hbwin/mapi.c index a371cb7d33..e5d50f1a1b 100644 --- a/harbour/contrib/hbwin/mapi.c +++ b/harbour/contrib/hbwin/mapi.c @@ -71,7 +71,7 @@ #endif #if defined( __WATCOMC__ ) -typedef ULONG (PASCAL * LPMAPISENDMAIL) (LHANDLE,ULONG,lpMapiMessage,FLAGS,ULONG); +typedef ULONG ( PASCAL * LPMAPISENDMAIL ) ( LHANDLE, ULONG, lpMapiMessage, FLAGS, ULONG ); #endif HB_FUNC( WIN_MAPISENDMAIL ) diff --git a/harbour/contrib/hbwin/win_prn3.c b/harbour/contrib/hbwin/win_prn3.c index 95057d9933..a70aeb1c5b 100644 --- a/harbour/contrib/hbwin/win_prn3.c +++ b/harbour/contrib/hbwin/win_prn3.c @@ -67,35 +67,36 @@ #include "hbwinuni.h" /* NOTE: Based on hb_strncat() */ -static TCHAR * hb_tstrncat( TCHAR * pDest, const TCHAR * pSource, ULONG ulLen ) +static TCHAR * hb_tstrncat( TCHAR * pDest, const TCHAR * pSource, HB_SIZE nLen ) { TCHAR * pBuf = pDest; - HB_TRACE(HB_TR_DEBUG, ("hb_tstrncat(%p, %p, %lu)", pDest, pSource, ulLen)); + HB_TRACE(HB_TR_DEBUG, ("hb_tstrncat(%p, %p, %lu)", pDest, pSource, nLen)); - pDest[ ulLen ] = '\0'; + pDest[ nLen ] = '\0'; - while( ulLen && *pDest ) + while( nLen && *pDest ) { pDest++; - ulLen--; + nLen--; } - while( ulLen-- && ( *pDest++ = *pSource++ ) ) {}; + while( nLen && ( *pDest++ = *pSource++ ) != '\0' ) + nLen--; return pBuf; } -static ULONG hb_tstrlen( const TCHAR * pText ) +static HB_SIZE hb_tstrlen( const TCHAR * pText ) { - ULONG ul = 0; + HB_SIZE nLen = 0; HB_TRACE(HB_TR_DEBUG, ("hb_tstrlen(%p)", pText)); - while( pText[ ul ] ) - ++ul; + while( pText[ nLen ] ) + ++nLen; - return ul; + return nLen; } static HB_BOOL hb_SetDefaultPrinter( LPCTSTR lpPrinterName )