diff --git a/libs/ardour/audio_unit.cc b/libs/ardour/audio_unit.cc index 5423fc1688..add2407f84 100644 --- a/libs/ardour/audio_unit.cc +++ b/libs/ardour/audio_unit.cc @@ -2053,7 +2053,7 @@ AUPlugin::find_presets () user_preset_map.clear (); - find_files_matching_filter (preset_files, preset_search_path, au_preset_filter, this, true, true, -1, true); + find_files_matching_filter (preset_files, preset_search_path, au_preset_filter, this, true, true, true); if (preset_files.empty()) { return; diff --git a/libs/ardour/panner_manager.cc b/libs/ardour/panner_manager.cc index c23d6b5951..3be16e4d48 100644 --- a/libs/ardour/panner_manager.cc +++ b/libs/ardour/panner_manager.cc @@ -95,7 +95,7 @@ PannerManager::discover_panners () DEBUG_TRACE (DEBUG::Panning, string_compose (_("looking for panners in %1\n"), search_path)); - find_files_matching_filter (panner_modules, search_path, panner_filter, 0, false, true, 1, true); + find_files_matching_filter (panner_modules, search_path, panner_filter, 0, false, true, true); for (vector::iterator i = panner_modules.begin(); i != panner_modules.end(); ++i) { panner_discover (*i); diff --git a/libs/pbd/file_utils.cc b/libs/pbd/file_utils.cc index 7dd65e8bc4..8348049c8f 100644 --- a/libs/pbd/file_utils.cc +++ b/libs/pbd/file_utils.cc @@ -227,7 +227,7 @@ find_files_matching_regex (vector& result, find_files_matching_filter (result, dirpath, regexp_filter, &compiled_pattern, - true, true, -1, false); + true, true, false); regfree (&compiled_pattern); } @@ -238,7 +238,6 @@ find_files_matching_filter (vector& result, bool (*filter)(const string &, void *), void *arg, bool match_fullpath, bool return_fullpath, - long limit, bool recurse) { DIR *dir; @@ -277,7 +276,7 @@ find_files_matching_filter (vector& result, } if (statbuf.st_mode & S_IFDIR && recurse) { - find_files_matching_filter (result, fullpath, filter, arg, match_fullpath, return_fullpath, limit, recurse); + find_files_matching_filter (result, fullpath, filter, arg, match_fullpath, return_fullpath, recurse); } else { if (match_fullpath) { @@ -295,13 +294,11 @@ find_files_matching_filter (vector& result, } else { result.push_back(finfo->d_name); } - - nfound++; } } closedir (dir); - } while ((limit < 0 || (nfound < limit)) && (thisdir = strtok_r (0, G_SEARCHPATH_SEPARATOR_S, &saveptr))); + } while ((thisdir = strtok_r (0, G_SEARCHPATH_SEPARATOR_S, &saveptr))); free (pathcopy); return; diff --git a/libs/pbd/pbd/file_utils.h b/libs/pbd/pbd/file_utils.h index 2ae26f801e..b23ee1ebc8 100644 --- a/libs/pbd/pbd/file_utils.h +++ b/libs/pbd/pbd/file_utils.h @@ -127,7 +127,6 @@ find_files_matching_filter (std::vector&, void *arg, bool match_fullpath, bool return_fullpath, - long limit = -1, bool recurse = false); /**