osaf/libs/common/immsv/immpbe_dump.cc | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
Add integer casting in verifyAttributeValuePBE to avoid mismatch between
integer signs and integer type size
diff --git a/osaf/libs/common/immsv/immpbe_dump.cc
b/osaf/libs/common/immsv/immpbe_dump.cc
--- a/osaf/libs/common/immsv/immpbe_dump.cc
+++ b/osaf/libs/common/immsv/immpbe_dump.cc
@@ -1149,17 +1149,17 @@ static bool verifyAttributeValuePBE(cons
return strtof(attrVal, NULL) == *(float *)value;
case SA_IMM_ATTR_SAUINT32T:
- return strtoul(attrVal, NULL, 10) == *(SaUint32T
*)value;
+ return (SaUint32T)strtoul(attrVal, NULL, 10) ==
*(SaUint32T *)value;
case SA_IMM_ATTR_SAINT32T:
- return strtol(attrVal, NULL, 10) == *(SaInt32T *)value;
+ return (SaInt32T)strtol(attrVal, NULL, 10) ==
*(SaInt32T *)value;
case SA_IMM_ATTR_SAUINT64T:
- return strtoull(attrVal, NULL, 10) == *(SaUint64T
*)value;
+ return (SaUint64T)strtoull(attrVal, NULL, 10) ==
*(SaUint64T *)value;
case SA_IMM_ATTR_SATIMET:
case SA_IMM_ATTR_SAINT64T:
- return strtoll(attrVal, NULL, 10) == *(SaInt64T *)value;
+ return (SaInt64T)strtoll(attrVal, NULL, 10) ==
*(SaInt64T *)value;
case SA_IMM_ATTR_SASTRINGT:
return strcmp(attrVal, *(SaStringT *)value) == 0;
------------------------------------------------------------------------------
_______________________________________________
Opensaf-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensaf-devel