C++17: fix name collision. am: 19306140a3 am: ec31cb7ae0
am: d42e987976

Change-Id: Ic514e1307e0ad3009bb0bda98be6777229080050
diff --git a/transport/ServiceManagement.cpp b/transport/ServiceManagement.cpp
index 40a7ff5..e7bec41 100644
--- a/transport/ServiceManagement.cpp
+++ b/transport/ServiceManagement.cpp
@@ -238,9 +238,8 @@
     return gDefaultServiceManager;
 }
 
-std::vector<std::string> search(const std::string &path,
-                              const std::string &prefix,
-                              const std::string &suffix) {
+static std::vector<std::string> findFiles(const std::string& path, const std::string& prefix,
+                                          const std::string& suffix) {
     std::unique_ptr<DIR, decltype(&closedir)> dir(opendir(path.c_str()), closedir);
     if (!dir) return {};
 
@@ -388,7 +387,7 @@
 #endif
 
         for (const std::string& path : paths) {
-            std::vector<std::string> libs = search(path, prefix, ".so");
+            std::vector<std::string> libs = findFiles(path, prefix, ".so");
 
             for (const std::string &lib : libs) {
                 const std::string fullPath = path + lib;
@@ -509,7 +508,7 @@
         for (const auto &pair : sAllPaths) {
             Arch arch = pair.first;
             for (const auto &path : pair.second) {
-                std::vector<std::string> libs = search(path, "", ".so");
+                std::vector<std::string> libs = findFiles(path, "", ".so");
                 for (const std::string &lib : libs) {
                     std::string matchedName;
                     std::string implName;