Fixes failing DCHECK in dex2oatd (cherry picked from commit 3df47c1c) Change-Id: I96a3b582705e4bffa39ee8e24ec43ff0d7a57ccd