Merge "Open image files in binary mode"

am: 744677aaf5

Change-Id: I09e6672afb96324fa94da162a0be1226a1ff4174
This commit is contained in:
Hridya Valsaraju 2019-04-03 22:05:59 -07:00 committed by android-build-merger
commit 70c0861e22

View file

@ -1407,7 +1407,7 @@ bool LocalImageSource::ReadFile(const std::string& name, std::vector<char>* out)
int LocalImageSource::OpenFile(const std::string& name) const {
auto path = find_item_given_name(name);
return open(path.c_str(), O_RDONLY);
return open(path.c_str(), O_RDONLY | O_BINARY);
}
static void do_flashall(const std::string& slot_override, bool skip_secondary, bool wipe) {