DO NOT MERGE - SoftMPEG4: Check the buffer size before writing the reference frame. am: 180185da19  -s ours am: 5d50c6e5e0 am: 9cb824f404 am: b037147760  -s ours am: 7db383ebb7 am: 3906f11f59 am: 882f8416b2 am: a90c79f0b4  -s ours am: 98f19e2224
am: 0068cf96cb

Change-Id: I5dafadb52dd3b8eefd69522e2eba387e4b8b5142