diff options
author | Alexander Kutsan <akutsan@luxoft.com> | 2017-09-05 19:02:36 +0300 |
---|---|---|
committer | Alexander Kutsan <akutsan@luxoft.com> | 2017-09-05 19:02:36 +0300 |
commit | 0135245320f082b76aaa38cedb1f63177793f900 (patch) | |
tree | 13f91daec0a62c72e7aae368df7ba4b3aff69058 | |
parent | 4c50e44f511d93b494ae43c748402089b4b70be8 (diff) | |
download | sdl_core-0135245320f082b76aaa38cedb1f63177793f900.tar.gz |
Remove unused HaveGroupsChanged function
-rw-r--r-- | src/components/policy/policy_external/src/policy_helper.cc | 24 | ||||
-rw-r--r-- | src/components/policy/policy_regular/src/policy_helper.cc | 25 |
2 files changed, 0 insertions, 49 deletions
diff --git a/src/components/policy/policy_external/src/policy_helper.cc b/src/components/policy/policy_external/src/policy_helper.cc index 6594221f22..3041323489 100644 --- a/src/components/policy/policy_external/src/policy_helper.cc +++ b/src/components/policy/policy_external/src/policy_helper.cc @@ -866,28 +866,4 @@ bool UnwrapAppPolicies(policy_table::ApplicationPolicies& app_policies) { return true; } -#ifdef SDL_REMOTE_CONTROL -bool HaveGroupsChanged(const rpc::Optional<policy_table::Strings>& old_groups, - const rpc::Optional<policy_table::Strings>& new_groups) { - if (!old_groups.is_initialized() && !new_groups.is_initialized()) { - return false; - } - if (!old_groups.is_initialized() || !new_groups.is_initialized()) { - return true; - } - policy_table::Strings old_groups_abs = *old_groups; - policy_table::Strings new_groups_abs = *new_groups; - if (old_groups_abs.size() != new_groups_abs.size()) { - return true; - } - std::sort(new_groups_abs.begin(), new_groups_abs.end(), Compare); - std::sort(old_groups_abs.begin(), old_groups_abs.end(), Compare); - - return std::equal(new_groups_abs.begin(), - new_groups_abs.end(), - old_groups_abs.begin(), - Compare); -} - -#endif // SDL_REMOTE_CONTROL } // namespace policy diff --git a/src/components/policy/policy_regular/src/policy_helper.cc b/src/components/policy/policy_regular/src/policy_helper.cc index f438b4317c..b72a041a83 100644 --- a/src/components/policy/policy_regular/src/policy_helper.cc +++ b/src/components/policy/policy_regular/src/policy_helper.cc @@ -802,29 +802,4 @@ bool UnwrapAppPolicies(policy_table::ApplicationPolicies& app_policies) { return true; } - -#ifdef SDL_REMOTE_CONTROL -bool HaveGroupsChanged(const rpc::Optional<policy_table::Strings>& old_groups, - const rpc::Optional<policy_table::Strings>& new_groups) { - if (!old_groups.is_initialized() && !new_groups.is_initialized()) { - return false; - } - if (!old_groups.is_initialized() || !new_groups.is_initialized()) { - return true; - } - policy_table::Strings old_groups_abs = *old_groups; - policy_table::Strings new_groups_abs = *new_groups; - if (old_groups_abs.size() != new_groups_abs.size()) { - return true; - } - std::sort(new_groups_abs.begin(), new_groups_abs.end(), Compare); - std::sort(old_groups_abs.begin(), old_groups_abs.end(), Compare); - - return std::equal(new_groups_abs.begin(), - new_groups_abs.end(), - old_groups_abs.begin(), - Compare); -} - -#endif // SDL_REMOTE_CONTROL } |