Camera: Prevent data size overflow

Add a function to check overflow when calculating metadata
data size.

Bug: 30741779
Change-Id: I6405fe608567a4f4113674050f826f305ecae030

static camera_metadata_buffer_entry_t *get_entries(
 const camera_metadata_t *metadata) {
 return (camera_metadata_buffer_entry_t*)
 ((uint8_t*)metadata + metadata->entries_start);
}

static camera_metadata_buffer_entry_t *get_entries(
 const camera_metadata_t *metadata) {
 return (camera_metadata_buffer_entry_t*)
 ((uint8_t*)metadata + metadata->entries_start);
}
