Fix multi-line hex dumping and add unit test.

Change-Id: I7657018fef5d9c17410a9a634db275555f180014
8 files changed