Merge "Work around an angler bootloader bug."
am: 9eab787560
* commit '9eab7875602dec9910002f080df513077f56a2dd':
Work around an angler bootloader bug.
This commit is contained in:
commit
d09dc85d63
1 changed files with 4 additions and 0 deletions
|
|
@ -44,6 +44,7 @@
|
|||
#include <unistd.h>
|
||||
|
||||
#include <base/parseint.h>
|
||||
#include <base/strings.h>
|
||||
#include <sparse/sparse.h>
|
||||
#include <ziparchive/zip_archive.h>
|
||||
|
||||
|
|
@ -580,6 +581,9 @@ static int64_t get_target_sparse_limit(usb_handle* usb) {
|
|||
return 0;
|
||||
}
|
||||
|
||||
// Some bootloaders (angler, for example) send spurious whitespace too.
|
||||
max_download_size = android::base::Trim(max_download_size);
|
||||
|
||||
uint64_t limit;
|
||||
if (!android::base::ParseUint(max_download_size.c_str(), &limit)) {
|
||||
fprintf(stderr, "couldn't parse max-download-size '%s'\n", max_download_size.c_str());
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue