Print operation names using InstallOperationTypeName().
PayloadFile had a local array to convert from the operation type enum
to a human-readable string name. Since the enum is converted to an int
this method will not fail to compile whenever new operations are added.
This patch removes such array and uses the existing
InstallOperationTypeName() function to convert the enum to string. This
fixes a buffer overflow in test code that generates new operations.
Bug: chromium:543593
Test: USE="clang asan" FEATURES=test emerge-link update_engine
Change-Id: Ib8d80711d039edf18a323aefaad4ce96e5dfc2e3
1 file changed