Enable readability-implicit-bool-conversion checks
These checks ensure that we're not implicitly converting ints or
pointers into bools, which makes the code easier to read.
Tested:
Ran series through redfish service validator. No changes observed.
UUID failing in Qemu both before and after.
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: I1ca0be980d136bd4e5474341f4fd62f2f6bbdbae
diff --git a/redfish-core/lib/event_service.hpp b/redfish-core/lib/event_service.hpp
index 6088758..9ce2f05 100644
--- a/redfish-core/lib/event_service.hpp
+++ b/redfish-core/lib/event_service.hpp
@@ -359,7 +359,7 @@
if (value == nullptr)
{
messages::propertyValueFormatError(
- asyncResp->res, item.value().dump(2, true),
+ asyncResp->res, item.value().dump(2, 1),
"HttpHeaders/" + item.key());
return;
}
@@ -432,7 +432,8 @@
registry.begin(), registry.end(),
[&id](const redfish::message_registries::
MessageEntry& messageEntry) {
- return !id.compare(messageEntry.first);
+ return id.compare(messageEntry.first) ==
+ 0;
}))
{
validId = true;