certificate-service: fix clang-tidy warnings
```
../redfish-core/lib/certificate_service.hpp:154:32: error: 'i' is an unsafe pointer used for buffer access [-Werror,-Wunsafe-buffer-usage]
std::string_view::iterator i = value.begin();
```
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I6b6fb17d58bb7a3bd861aaf020540586490693da
diff --git a/redfish-core/lib/certificate_service.hpp b/redfish-core/lib/certificate_service.hpp
index 3cb6a3f..dcbff2d 100644
--- a/redfish-core/lib/certificate_service.hpp
+++ b/redfish-core/lib/certificate_service.hpp
@@ -157,18 +157,18 @@
std::string_view::iterator tokenBegin = i;
while (i != value.end() && *i != '=')
{
- ++i;
+ std::advance(i, 1);
}
if (i == value.end())
{
break;
}
std::string_view key(tokenBegin, static_cast<size_t>(i - tokenBegin));
- ++i;
+ std::advance(i, 1);
tokenBegin = i;
while (i != value.end() && *i != ',')
{
- ++i;
+ std::advance(i, 1);
}
std::string_view val(tokenBegin, static_cast<size_t>(i - tokenBegin));
if (key == "L")
@@ -198,7 +198,7 @@
// skip comma character
if (i != value.end())
{
- ++i;
+ std::advance(i, 1);
}
}
}