diff options
author | Elliott Hughes <enh@google.com> | 2015-11-02 14:05:57 -0800 |
---|---|---|
committer | Elliott Hughes <enh@google.com> | 2015-11-02 14:05:57 -0800 |
commit | 8ab9a32323cee1f23c5ccbfeabd2cb2253f693d2 (patch) | |
tree | 76f2bf1391ec984a38a13d29877a158c05b89ae4 /fastboot/engine.cpp | |
parent | 36d7af4cf635816ecbcb9bd300f4c9d60cb012d4 (diff) |
Clarify and fix the intent of the partition-type checking code.
Change-Id: I202dab4ee91208b632bc2086d1e5c387a4c29edd
Diffstat (limited to 'fastboot/engine.cpp')
-rw-r--r-- | fastboot/engine.cpp | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/fastboot/engine.cpp b/fastboot/engine.cpp index 63e89714a..44796d7d9 100644 --- a/fastboot/engine.cpp +++ b/fastboot/engine.cpp @@ -88,24 +88,6 @@ bool fb_getvar(usb_handle* usb, const std::string& key, std::string* value) { return true; } - -// Return true if this partition is supported by the fastboot format command. -// It is also used to determine if we should first erase a partition before -// flashing it with an ext4 filesystem. See needs_erase() -// -// Not all devices report the filesystem type, so don't report any errors, -// just return false. -bool fb_format_supported(usb_handle *usb, const char *partition, const char *type_override) { - if (type_override) { - return fs_get_generator(type_override) != nullptr; - } - std::string partition_type; - if (!fb_getvar(usb, std::string("partition-type:") + partition, &partition_type)) { - return false; - } - return fs_get_generator(partition_type.c_str()) != nullptr; -} - static int cb_default(Action* a, int status, const char* resp) { if (status) { fprintf(stderr,"FAILED (%s)\n", resp); |