2007-06-06 15:40 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)

* harbour/include/hbregex.h
  * harbour/source/rtl/hbregex.c
    ! fixed GPF and removed two hacks
This commit is contained in:
Przemyslaw Czerpak
2007-06-06 13:40:09 +00:00
parent d16e229f47
commit 40774efc91
3 changed files with 7 additions and 5 deletions

View File

@@ -8,6 +8,11 @@
2002-12-01 13:30 UTC+0100 Foo Bar <foo.bar@foobar.org>
*/
2007-06-06 15:40 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/include/hbregex.h
* harbour/source/rtl/hbregex.c
! fixed GPF and removed two hacks
2007-06-06 14:02 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/source/rtl/hbregex.c
! added workaround for some wrong hack (to check if both can be

View File

@@ -94,7 +94,7 @@ typedef HB_REGEX * PHB_REGEX;
#if defined( HB_PCRE_REGEX )
#define HB_REGMATCH int
#define HB_REGMATCH_SIZE( n ) ( ( n + 1 ) * 3 )
#define HB_REGMATCH_SIZE( n ) ( ( n ) * 3 )
#define HB_REGMATCH_SO( p, n ) ( p )[ ( n ) * 2 ]
#define HB_REGMATCH_EO( p, n ) ( p )[ ( n ) * 2 + 1 ]
#elif defined( HB_POSIX_REGEX )

View File

@@ -106,12 +106,9 @@ static int hb_regexec( PHB_REGEX pRegEx, const char * szString, ULONG ulLen,
#if defined( HB_PCRE_REGEX )
int iResult, i;
for( i = 0; i < iMatches; i++ )
HB_REGMATCH_EO( aMatches, i ) = -1;
iResult = pcre_exec( pRegEx->re_pcre, NULL /* pcre_extra */,
szString, ulLen, 0 /* startoffset */,
pRegEx->iEFlags, aMatches, iMatches + 1 );
pRegEx->iEFlags, aMatches, HB_REGMATCH_SIZE( iMatches ) );
if( iResult == 0 )
{
for( i = 0; i < iMatches; i++ )