path = path.substr(pos+1);
}
- /* remove filename suffixes etc. */
+ /* remove filename suffixes etc. */
if ((pos = path.find_last_of ('.')) != string::npos) {
path = path.substr (0, pos);
}
else if (val <= METER_FALLOFF_FASTER) {
return MeterFalloffFaster;
- }
+ }
else {
return MeterFalloffFastest;
}
{
/* to be used only with XML data - not intended to handle user input */
- if (str == "1" || str == "y" || str == "Y") {
- return true;
- } else {
- std::string str_uc;
- std::transform(str.begin(), str.end(), str_uc.begin(), ::toupper);
- if (str_uc == "YES") {
- return true;
- }
- }
- return false;
+ return str == "1" || str == "y" || str == "Y" || (!g_strncasecmp(str.c_str(), "yes", str.length()));
}
extern "C" {