diff options
author | 2023-06-06 21:48:40 +0000 | |
---|---|---|
committer | 2023-06-21 14:15:06 +0000 | |
commit | 19486a2ce17e7517a14a882649b286c23486cf08 (patch) | |
tree | 33579cdf453c5c441be73c2b544d672d8a7d01ea | |
parent | 906ed857cbf52db1147b42f471d1aba3cc74f3ed (diff) |
Revert "Cancel dumpstate if client disconnects"
This reverts commit 3d509846cfa9430575f9eb4dfb46957b04788638.
Bug: 268200878
Test: Attempting BR during an existing BR will result in an error
message and not abort the original Bug Report.
Ignore-AOSP-First: This patch reverts a change which is not in AOSP at all
Signed-off-by: Matt Delmage <mdelmage@google.com>
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:7ed14b44b7f540c98a2b1e61d5b953e7bf36fd96)
Merged-In: Idbb149b9e3f55bcb2426f1192b5239947055b4c9
Change-Id: Idbb149b9e3f55bcb2426f1192b5239947055b4c9
-rw-r--r-- | cmds/bugreportz/main.cpp | 17 | ||||
-rw-r--r-- | cmds/dumpstate/dumpstate.cpp | 6 |
2 files changed, 1 insertions, 22 deletions
diff --git a/cmds/bugreportz/main.cpp b/cmds/bugreportz/main.cpp index 790556ce5a..cd2652c717 100644 --- a/cmds/bugreportz/main.cpp +++ b/cmds/bugreportz/main.cpp @@ -75,23 +75,6 @@ int main(int argc, char* argv[]) { return EXIT_FAILURE; } - // Wait a little while for dumpstatez to stop if it is running - bool dumpstate_running = false; - for (int i = 0; i < 20; i++) { - char buf[PROPERTY_VALUE_MAX]; - property_get("init.svc.dumpstatez", buf, ""); - dumpstate_running = strcmp(buf, "running") == 0; - - if (!dumpstate_running) break; - - sleep(1); - } - - if (dumpstate_running) { - fprintf(stderr, "FAIL:dumpstatez service is already running\n"); - return EXIT_FAILURE; - } - // TODO: code below was copy-and-pasted from bugreport.cpp (except by the // timeout value); // should be reused instead. diff --git a/cmds/dumpstate/dumpstate.cpp b/cmds/dumpstate/dumpstate.cpp index ed1885b5fa..8a337569c4 100644 --- a/cmds/dumpstate/dumpstate.cpp +++ b/cmds/dumpstate/dumpstate.cpp @@ -2602,11 +2602,7 @@ static void ShowUsage() { } static void register_sig_handler() { - signal(SIGPIPE, [](int) { - MYLOGE("Connection with client lost, canceling."); - ds.Cancel(); - abort(); - }); + signal(SIGPIPE, SIG_IGN); } bool Dumpstate::FinishZipFile() { |