Replace MallocHelper with std::unique_ptr.

Obviously this code could be cleaned up more, but I doubt anyone wants to.
Minimal change to remove MallocHelper.

Bug: https://issuetracker.google.com/36982134
Test: builds, boots
Change-Id: I138739c281cc2ad9723d1eea3546bf5c797ade90
1 file changed