relocate applypatch; check patch integrity
- Delete the applypatch code (it's being moved to bootable/recovery).
- Change the OTA script generator to verify the sha1sum of all the
patch files after they are unpacked into /tmp.
b/2361316 - VZW Issue PP628: Continuous reset to Droid logo:
framework-res.apk update failed (CR LIBtt59130)
Change-Id: I5858d48f10127f72e708d50d3de844569d1aff27
diff --git a/tools/releasetools/edify_generator.py b/tools/releasetools/edify_generator.py
index 64bd547..900bad1 100644
--- a/tools/releasetools/edify_generator.py
+++ b/tools/releasetools/edify_generator.py
@@ -113,7 +113,7 @@
def PatchCheck(self, filename, *sha1):
"""Check that the given file (or MTD reference) has one of the
given *sha1 hashes."""
- self.script.append('assert(apply_patch_check("%s"' % (filename,) +
+ self.script.append('assert(sha1_check(read_file("%s")' % (filename,) +
"".join([', "%s"' % (i,) for i in sha1]) +
'));')