Fix out-of-bounds write
am: 5403587a74

* commit '5403587a74aee2fb57076528c3927851531c8afb':
  Fix out-of-bounds write