X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;ds=sidebyside;f=libs%2Fardour%2Fcontrol_protocol_search_path.cc;h=345989277bef662f571b17585dca960fe5d15efb;hb=204baa31d842d4c2f833d319b6fa55e402a1bfb8;hp=7cdf75a44137a6b646904a3a450b59619a1e318c;hpb=bb9cc45cd22af67ac275a5e73accbe14fee664d8;p=ardour.git diff --git a/libs/ardour/control_protocol_search_path.cc b/libs/ardour/control_protocol_search_path.cc index 7cdf75a441..345989277b 100644 --- a/libs/ardour/control_protocol_search_path.cc +++ b/libs/ardour/control_protocol_search_path.cc @@ -34,19 +34,17 @@ namespace ARDOUR { SearchPath control_protocol_search_path () { - bool surfaces_path_defined = false; - SearchPath spath_env(Glib::getenv(surfaces_env_variable_name, surfaces_path_defined)); - - if (surfaces_path_defined) - { - return spath_env; - } - - SearchPath spath(user_config_directory ()); + SearchPath spath (user_config_directory ()); spath += ardour_module_directory (); + spath.add_subdirectory_to_paths (surfaces_dir_name); - spath.add_subdirectory_to_paths(surfaces_dir_name); + bool surfaces_path_defined = false; + SearchPath spath_env (Glib::getenv(surfaces_env_variable_name, surfaces_path_defined)); + + if (surfaces_path_defined) { + spath += spath_env; + } return spath; }