Revert "Revert "Try to be consistent when setting fields of OatWriter::OatDexFile.""

This reverts commit 715d672e22953eb4d4a10b1b51a5584ee9b0e94e.

The bug in the initial CL was forgetting to set the
checksum in AddDexFileSource.
I've added a test in oat_writer_test to prevent this problem.

Test: oat_writer_test.cc

Change-Id: Ic9f4a723be32ee1ad00068f230763e587d56aa2f
3 files changed