M
mainland
I use prce to match string. I define a pcre struct point, then
compile, pass pcre struct point to 'pcre_compile'.
When complete, Is it necessary to use 'pcre_free' to free pcre struct
point.
example:
.......
pcre *re;
const char* errorptr;
int erroroffset;
re = pcre_compile ( "pattern", 0 , &errorptr, &erroroffset, 0);
..... do samething .....
if ( re != NULL )
{
pcre_free ( re );
re = NULL;
}
.......
And, Is 'pcre_free' thread safe ???
compile, pass pcre struct point to 'pcre_compile'.
When complete, Is it necessary to use 'pcre_free' to free pcre struct
point.
example:
.......
pcre *re;
const char* errorptr;
int erroroffset;
re = pcre_compile ( "pattern", 0 , &errorptr, &erroroffset, 0);
..... do samething .....
if ( re != NULL )
{
pcre_free ( re );
re = NULL;
}
.......
And, Is 'pcre_free' thread safe ???