Merge changes from topic "presubmit-am-870422bebde9449d9c143a13fd15d1bd" into sc-v2-dev-plus-aosp

* changes:
  [automerge] Check incoming array sizes before accessing. 2p: 81061238c1
  Check incoming array sizes before accessing.