SS_FSUpdate: Fix to cast into bigger type before operation 15/317315/1
authorSangYoun Kwak <sy.kwak@samsung.com>
Mon, 30 Dec 2024 09:38:41 +0000 (18:38 +0900)
committerSangYoun Kwak <sy.kwak@samsung.com>
Mon, 30 Dec 2024 09:46:07 +0000 (18:46 +0900)
commit434532841fdbd8dcf433fedecfd0937275cb8474
tree02b3218d1ab1d6ab6237f8b9c8a27ad92a2c3c1b
parentd5e1fe8a38e176aa105b0e8408653d4796921124
SS_FSUpdate: Fix to cast into bigger type before operation

Since the operands are int, SS_UINT32(unsigned int) and long type, it is
required to cast them into a big enough type before adding them.
(Thier value are all non-negative values)

To resolve this issue, operands are casted to uint64_t, which is big
enough to store the value of the variables and the result of the
arithmetic operation.

Change-Id: Iecf8ffa3be11984ce6fdc3d850f9b9c9f74c7186
Signed-off-by: SangYoun Kwak <sy.kwak@samsung.com>
src/upgrade-apply-deltafs/engine/SS_FSUpdate.c