Fixed to AttributesImpl.getIndex from Isak Johnsson. Thanks go to him and a "what on earth was I thinking" to me.

This commit is contained in:
jez 2007-10-25 20:57:40 +00:00
parent af3ebfde60
commit fa235dc7af

View file

@ -188,7 +188,7 @@ public:
{
typename AttrList::const_iterator a = std::find_if(attributes_.begin(), attributes_.end(), AttributeNamed(uri, localName));
if(a != attributes_.end())
return static_cast<int>(std::distance(a, attributes_.end()));
return static_cast<int>(std::distance(attributes_.begin(), a));
return -1;
} // getIndex