PluginInfo::type added to copy constructor. But why is the copy constructor defined...
[ardour.git] / libs / ardour / utils.cc
index 8fd5ca499fde204e188638c4389b2365e1903341..98b51cb5786be34d9922d65ef1ea4a724c69d9ac 100644 (file)
@@ -581,21 +581,13 @@ ARDOUR::auto_style_to_string (AutoStyle as)
        /*NOTREACHED*/
        return "";
 }
+
 bool
 string_is_affirmative (const std::string& str)
 {
        /* 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" {