As part of enabling -Wconditional-uninitialized, there are some false
positives. See https://bugs.llvm.org/show_bug.cgi?id=38856 for more info
about the limited flow analysis. To facilitate turning this flag on more
widely, we can just directly initialize these variables.
Bug: http://b/131390872
Test: Builds with -Wconditional-uninitialized.
Change-Id: Id6633a06478dfb0c51a1a3b0cabf4c4e5d57abaa
Dumpstate now supports zipped bugreport, whose output is more complete
than the flat-file bugreports provided prior to N.
The whole workflow is split in different components:
- adb supports a 'bugreport -z <ZIP_FILE>' option, which calls a
bugreportz binary.
- bugreportz starts the dumpstatez service.
- dumpstatez starts dumpstate with some flags that opens a socket for
control (not output).
- Once dumpstate is finished, it prints the bugreport location to
stdout.
- adb pulls the zip file and renames according to the command-line
argument.
- bugreport prints a deprecation message.
The reason for a new binary (bugreportz) instead of passing arguments to
bugreport (like -z) is backward compatibility: pre-N versions of
bugreport would ignore such argument and generate a text bugreport,
which is not what adb would be expecting.
BUG: 27653204
Change-Id: I47f6f677eba11d5fb54818ae5a0b3cab069776ee
Implemented these changes:
- Make this code C++.
- Avoid hangs by adding a timeout.
- Add the necessary TEMP_FAILURE_RETRY calls.
- Restructure the code a bit.
Bug: 18800936
Change-Id: Iba9f86a4c7beee4f0f36e51234855f4c0834db47