library/src/blockclass/subclasses/BP_StringUtils.cc
// destroy the registry find and replace
destroy the registry find and replace
destroy the registry find and replace
bool BP_StringUtils::DestroyRegFindReplaceData()
{
	if(this->mod_string)
	{
		tq_free(this->tq, mod_string);
	}
	size_t n = 0;
	for(; n < this->find_item_count; n++)
	{
		if(this->find_strs[n])
			tq_free(this->tq, this->find_strs[n]);
		if(this->replace_strs[n])
			tq_free(this->tq, this->replace_strs[n]);
	}
	if(this->find_strs)
	{
		tq_free(this->tq, this->find_strs);
	}
	if(this->replace_strs)
	{
		tq_free(this->tq, this->replace_strs);
	}
	return true;
}
bool BP_StringUtils :: DestroyRegFindReplaceData ( ) { if ( this -> mod_string ) { tq_free ( this -> tq , mod_string ) ; } size_t n = 0 ; for ( ; n < this -> find_item_count ; n ++ ) { if ( this -> find_strs [ n ] ) tq_free ( this -> tq , this -> find_strs [ n ] ) ; if ( this -> replace_strs [ n ] ) tq_free ( this -> tq , this -> replace_strs [ n ] ) ; } if ( this -> find_strs ) { tq_free ( this -> tq , this -> find_strs ) ; } if ( this -> replace_strs ) { tq_free ( this -> tq , this -> replace_strs ) ; } return true ; }
destroy the registry find and replace
destroy the registry find and replace
// walk each entry and destroy // check for find strings // check for find strings // return indicating success