OSDN Git Service

Fixed check if zip file was generated properly.
authorFelipe Leme <felipeal@google.com>
Thu, 19 Nov 2015 23:30:35 +0000 (15:30 -0800)
committerFelipe Leme <felipeal@google.com>
Thu, 19 Nov 2015 23:30:35 +0000 (15:30 -0800)
During the earlier development stages, this function was returning an
int and later it was changed to boolean, but the check was not updated.

BUG: 25563823
Change-Id: I77f50bf2184d5dd4da2156a5eca4c8a555b567a4

cmds/dumpstate/dumpstate.cpp

index 369a29f..b349a23 100644 (file)
@@ -853,7 +853,7 @@ int main(int argc, char *argv[]) {
         bool do_text_file = true;
         if (do_zip_file) {
             path = zip_path;
-            if (generate_zip_file(tmp_path, zip_path, entry_name, now)) {
+            if (!generate_zip_file(tmp_path, zip_path, entry_name, now)) {
                 ALOGE("Failed to generate zip file; sending text bugreport instead\n");
                 do_text_file = true;
             } else {