int compare_no_case(string const & s, string const & s2)
{
- // ANSI C
string::const_iterator p = s.begin();
string::const_iterator p2 = s2.begin();
++p;
++p2;
}
-
+
if (s.size() == s2.size())
return 0;
if (s.size() < s2.size())
++p;
++p2;
}
- if (s.size() == s2.size())
+
+ if (s.size() >= len && s2.size() >= len)
return 0;
if (s.size() < s2.size())
return -1;
string::size_type const prelen = pre.length();
string::size_type const alen = a.length();
- if (prelen < alen || a.empty())
+ if (prelen > alen || a.empty())
return false;
else {
#if !defined(USE_INCLUDED_STRING) && !defined(STD_STRING_IS_GOOD)