From aa9f9e35690cebd1af0a6425213b9ba7e21cdd86 Mon Sep 17 00:00:00 2001 From: Pritpal Bedi Date: Sun, 11 Nov 2012 02:48:06 +0000 Subject: [PATCH] 2012-11-10 18:32 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com) * src/rtl/rat.c % Small optimization. --- harbour/ChangeLog | 4 ++++ harbour/src/rtl/rat.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 6fe399f30c..538e0a39c2 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -16,6 +16,10 @@ The license applies to all entries newer than 2009-04-28. */ +2012-11-10 18:32 UTC-0800 Pritpal Bedi (bedipritpal@hotmail.com) + * src/rtl/rat.c + % Small optimization. + 2012-11-11 02:38 UTC+0100 Viktor Szakats (harbour syenar.net) + extras/gtwvw/wvt2wvw.ch - extras/gtwvw/tests/wvt2wvw.ch diff --git a/harbour/src/rtl/rat.c b/harbour/src/rtl/rat.c index 03178aae29..11d99e643c 100644 --- a/harbour/src/rtl/rat.c +++ b/harbour/src/rtl/rat.c @@ -65,6 +65,7 @@ HB_FUNC( RAT ) if( nTo >= 0 ) { + PHB_CODEPAGE cdp = hb_vmCDP(); const char * pszSub = hb_parc( 1 ); const char * pszText = hb_parc( 2 ); @@ -73,7 +74,6 @@ HB_FUNC( RAT ) if( pszText[ nTo ] == *pszSub && memcmp( pszSub, pszText + nTo, nSubLen ) == 0 ) { - PHB_CODEPAGE cdp = hb_vmCDP(); if( HB_CDP_ISCHARIDX( cdp ) ) nPos = hb_cdpTextLen( cdp, pszText, nTo ) + 1; else