Fix coverity issue 38/294938/1
authorYoungjae Cho <y0.cho@samsung.com>
Thu, 29 Jun 2023 04:17:27 +0000 (13:17 +0900)
committerYoungjae Cho <y0.cho@samsung.com>
Thu, 29 Jun 2023 04:33:04 +0000 (13:33 +0900)
commit1b9d0a1d41bc7f7a919db5f6d494e52862760fa8
treedf15278a904c331949ddc79147f05a4997a71bcd
parentf3871aef8727bd4a52a17091e98c10028e2a523d
Fix coverity issue

When comparing operands that containing sizeof operator, both are taken
as unsigned. Therefore if an operand was -1, which might be a value of
error return, it is interpreted as unsigned value such as 4294967295
when it is compared with another operand, sizeof value. Make both
operands be signed by casting sizeof value into glong.

Change-Id: I116c507f50ad93f7b699c2524868e3c72979c376
Signed-off-by: Youngjae Cho <y0.cho@samsung.com>
src/common/tlm-utils.c
src/plugins/default/tlm-account-plugin-default.c