Merge "Check for errors in dup2" am: b1166633b6 am: 1d5d475b51
am: 7748fcf911

Change-Id: Idfb0af866594647a43832d1cbc1b7a597f139144