From cc8ddca9bd78913ed50ef8cbd6a2d2c095823f1a Mon Sep 17 00:00:00 2001 From: that Date: Sat, 3 Jan 2015 01:59:36 +0100 Subject: fix adb sideload - "Cancel" button handling requires another thread - simplify handling of child pid - merge duplicated code for reinjecting TWRP after installation - fix error that showed on host PC after sideload finished - fix problem where adbd sometimes does not stop correctly Change-Id: I536877f024b606756c6a3289c6ddfdba423a60d6 --- twrp.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'twrp.cpp') diff --git a/twrp.cpp b/twrp.cpp index e0b335975..35404c34d 100644 --- a/twrp.cpp +++ b/twrp.cpp @@ -77,6 +77,7 @@ int main(int argc, char **argv) { // Handle ADB sideload if (argc == 3 && strcmp(argv[1], "--adbd") == 0) { + property_set("ctl.stop", "adbd"); adb_main(argv[2]); return 0; } @@ -95,7 +96,7 @@ int main(int argc, char **argv) { property_set("ro.twrp.version", TW_VERSION_STR); time_t StartupTime = time(NULL); - printf("Starting TWRP %s on %s (pid %d)", TW_VERSION_STR, ctime(&StartupTime), getpid()); + printf("Starting TWRP %s on %s (pid %d)\n", TW_VERSION_STR, ctime(&StartupTime), getpid()); // Load default values to set DataManager constants and handle ifdefs DataManager::SetDefaultValues(); -- cgit v1.2.3