Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 50d8032

Browse files
SteveMacenskiWiktor-99
authored andcommittedNov 19, 2024·
Fix wShadow compile warning (#250)
Signed-off-by: Wiktor Bajor <wiktorbajor1@gmail.com>
1 parent fc2d015 commit 50d8032

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed
 

Diff for: ‎pluginlib/include/pluginlib/class_loader_imp.hpp

+5-5
Original file line numberDiff line numberDiff line change
@@ -488,12 +488,12 @@ std::string ClassLoader<T>::getClassLibraryPath(const std::string & lookup_name)
488488
RCUTILS_LOG_DEBUG_NAMED("pluginlib.ClassLoader",
489489
"Iterating through all possible paths where %s could be located...",
490490
library_name.c_str());
491-
for (auto it = paths_to_try.begin(); it != paths_to_try.end(); it++) {
492-
RCUTILS_LOG_DEBUG_NAMED("pluginlib.ClassLoader", "Checking path %s ", it->c_str());
493-
if (rcpputils::fs::exists(*it)) {
491+
for (auto path_it = paths_to_try.begin(); path_it != paths_to_try.end(); path_it++) {
492+
RCUTILS_LOG_DEBUG_NAMED("pluginlib.ClassLoader", "Checking path %s ", path_it->c_str());
493+
if (rcpputils::fs::exists(*path_it)) {
494494
RCUTILS_LOG_DEBUG_NAMED("pluginlib.ClassLoader", "Library %s found at explicit path %s.",
495-
library_name.c_str(), it->c_str());
496-
return *it;
495+
library_name.c_str(), path_it->c_str());
496+
return *path_it;
497497
}
498498
}
499499
std::ostringstream error_msg;

0 commit comments

Comments
 (0)
Please sign in to comment.