libufdt: don't overflow when handling propeties > INT_MAX in size

Ensure property sizes (read as uint32_t) don't overflow the int return
value when being read.  Fix up _ufdt_output_property_to_fdt() to avoid
int overflow if a property len is near INT_MAX in size.

Bug: 259062118
Ignore-AOSP-First: Security
Test: mmma system/libufdt
Test: system/libufdt/tests/
Test: system/libufdt/tests/
Change-Id: I03a56f68a7e53d941809560b943153b8fc31decc
Merged-In: I03a56f68a7e53d941809560b943153b8fc31decc
2 files changed