You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@celix.apache.org by pn...@apache.org on 2019/01/07 20:11:59 UTC
[celix] 11/22: CELIX-438: Small refactoring for gcc 5 compiler
This is an automated email from the ASF dual-hosted git repository.
pnoltes pushed a commit to branch feature/cxx
in repository https://gitbox.apache.org/repos/asf/celix.git
commit 9f0369b66b6e21608dd56d983a2a37bbcdbb559d
Author: Pepijn Noltes <pe...@gmail.com>
AuthorDate: Sat Jan 5 18:45:23 2019 +0100
CELIX-438: Small refactoring for gcc 5 compiler
---
bundles/shell/cxx_shell/src/ShellActivator.cc | 2 +-
bundles/shell/cxx_shell_tui/src/ShellTuiActivator.cc | 2 +-
libs/registry/src/ServiceRegistry.cc | 6 +++---
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/bundles/shell/cxx_shell/src/ShellActivator.cc b/bundles/shell/cxx_shell/src/ShellActivator.cc
index 807a9b3..8d5d3fe 100644
--- a/bundles/shell/cxx_shell/src/ShellActivator.cc
+++ b/bundles/shell/cxx_shell/src/ShellActivator.cc
@@ -155,7 +155,7 @@ namespace {
manifest[celix::MANIFEST_BUNDLE_NAME] = "Shell";
manifest[celix::MANIFEST_BUNDLE_GROUP] = "Celix";
manifest[celix::MANIFEST_BUNDLE_VERSION] = "1.0.0";
- celix::registerStaticBundle<ShellBundleActivator>("celix::Shell", manifest, resources, resourcesLen);
+ celix::registerStaticBundle<ShellBundleActivator>("celix::Shell", std::move(manifest), resources, resourcesLen);
}
__attribute__((destructor))
diff --git a/bundles/shell/cxx_shell_tui/src/ShellTuiActivator.cc b/bundles/shell/cxx_shell_tui/src/ShellTuiActivator.cc
index ec48f6b..0958ab0 100644
--- a/bundles/shell/cxx_shell_tui/src/ShellTuiActivator.cc
+++ b/bundles/shell/cxx_shell_tui/src/ShellTuiActivator.cc
@@ -147,6 +147,6 @@ namespace {
manifest[celix::MANIFEST_BUNDLE_NAME] = "Shell Tui";
manifest[celix::MANIFEST_BUNDLE_GROUP] = "Celix";
manifest[celix::MANIFEST_BUNDLE_VERSION] = "1.0.0";
- celix::registerStaticBundle<ShellTuiBundleActivator>("celix::ShellTui", manifest);
+ celix::registerStaticBundle<ShellTuiBundleActivator>("celix::ShellTui", std::move(manifest));
}
}
\ No newline at end of file
diff --git a/libs/registry/src/ServiceRegistry.cc b/libs/registry/src/ServiceRegistry.cc
index 001b08e..58d5778 100644
--- a/libs/registry/src/ServiceRegistry.cc
+++ b/libs/registry/src/ServiceRegistry.cc
@@ -263,8 +263,8 @@ namespace {
//fill vector
std::lock_guard<std::mutex> lck{tracked.mutex};
rankedServices.reserve(tracked.entries.size());
- for (auto &tracked : tracked.entries) {
- rankedServices.push_back(std::make_tuple(tracked.second, &tracked.first->props, tracked.first->owner.get()));
+ for (auto &entry : tracked.entries) {
+ rankedServices.push_back(std::make_tuple(entry.second, &entry.first->props, entry.first->owner.get()));
}
}
if (opts.update) {
@@ -780,4 +780,4 @@ celix::ServiceTracker& celix::ServiceTracker::operator=(celix::ServiceTracker &&
int celix::ServiceTracker::trackCount() const { return pimpl ? pimpl->entry->count() : 0; }
const std::string& celix::ServiceTracker::serviceName() const { return pimpl? pimpl->entry->svcName : emptyString; }
const std::string& celix::ServiceTracker::filter() const { return pimpl ? pimpl->entry->filter.filterStr : emptyString; }
-bool celix::ServiceTracker::valid() const { return pimpl != nullptr; }
\ No newline at end of file
+bool celix::ServiceTracker::valid() const { return pimpl != nullptr; }