From 38b83c1da45f0b4a7d166bee73dc7701794874c3 Mon Sep 17 00:00:00 2001 From: bigbiff bigbiff Date: Thu, 28 Dec 2017 19:58:52 -0500 Subject: ADB Backup: fix md5 check on restore. Add debug capability. Fix backup of images after tarred partitions with too much padding Add more md5 logging. Skip digest check if selected. Change ADB Backup version to 3 for new fixes to image padding. Change-Id: I0f76c0733c523717e4797d1a14c3ae47d046fc8c --- adbbu/twrpback.hpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'adbbu/twrpback.hpp') diff --git a/adbbu/twrpback.hpp b/adbbu/twrpback.hpp index c52da3ea7..edc162651 100644 --- a/adbbu/twrpback.hpp +++ b/adbbu/twrpback.hpp @@ -42,6 +42,7 @@ private: int adb_control_bu_fd; // fd for twrp to bu communication int adb_read_fd; // adb read data stream int adb_write_fd; // adb write data stream + int debug_adb_fd; // fd to write debug tars bool firstPart; // first partition in the stream FILE *adbd_fp; // file pointer for adb stream char cmd[512]; // store result of commands @@ -54,6 +55,7 @@ private: void close_backup_fds(); // close backup resources void close_restore_fds(); // close restore resources bool checkMD5Trailer(char adbReadStream[], uint64_t md5fnsize, twrpMD5* digest); // Check MD5 Trailer + void printErrMsg(std::string msg, int errNum); // print error msg to adb log }; #endif // _TWRPBACK_HPP -- cgit v1.2.3