[GB.XML]
* BUG: Fix the Like-pattern matching of the XmlElement.GetChildrenByAttributeValue() method. git-svn-id: svn://localhost/gambas/trunk@6358 867c0c6c-44f3-4631-809d-bfa615b0a4ec
This commit is contained in:
parent
433b9fa9ac
commit
c2e7d79812
@ -388,10 +388,10 @@ void XMLNode_addGBChildrenByAttributeValue(Node *node, const char *attrName, con
|
||||
{
|
||||
if(node->type == Node::ElementNode)
|
||||
{
|
||||
Attribute *attr = XMLElement_GetAttribute((Element*)node, attrName, lenAttrName, mode);
|
||||
Attribute *attr = XMLElement_GetAttribute((Element*)node, attrName, lenAttrName);
|
||||
if(attr)
|
||||
{
|
||||
if(GB_MatchString(attr->attrValue, attr->lenAttrValue, attrValue, lenAttrValue))
|
||||
if(GB_MatchString(attr->attrValue, attr->lenAttrValue, attrValue, lenAttrValue, mode))
|
||||
{
|
||||
*(reinterpret_cast<void **>((GB.Array.Add(*array)))) = XMLNode_GetGBObject(node);
|
||||
GB.Ref(node->GBObject);
|
||||
|
@ -198,7 +198,7 @@ bool GB_MatchString(const char *str, size_t lenStr, const char *pattern, size_t
|
||||
}
|
||||
else if(mode == GB_STRCOMP_LIKE)
|
||||
{
|
||||
if(GB.MatchString(str, lenStr, pattern, lenPattern))
|
||||
if(GB.MatchString(pattern, lenPattern, str, lenStr) == true)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user