summaryrefslogtreecommitdiffstats
path: root/applypatch
diff options
context:
space:
mode:
authorBill Rassieur <rassb@google.com>2019-04-02 20:26:46 +0200
committerBill Rassieur <rassb@google.com>2019-04-02 20:26:46 +0200
commit86de943dcc7b81567514273be718e57703cf075c (patch)
treee9f635bd39b426228247ae3cf528f17061a55629 /applypatch
parentMerge master@5406228 into git_qt-dev-plus-aosp. (diff)
parentMerge changes Ibbe7084e,If584fc8a am: bb8f0fff17 am: effd4ca883 (diff)
downloadandroid_bootable_recovery-86de943dcc7b81567514273be718e57703cf075c.tar
android_bootable_recovery-86de943dcc7b81567514273be718e57703cf075c.tar.gz
android_bootable_recovery-86de943dcc7b81567514273be718e57703cf075c.tar.bz2
android_bootable_recovery-86de943dcc7b81567514273be718e57703cf075c.tar.lz
android_bootable_recovery-86de943dcc7b81567514273be718e57703cf075c.tar.xz
android_bootable_recovery-86de943dcc7b81567514273be718e57703cf075c.tar.zst
android_bootable_recovery-86de943dcc7b81567514273be718e57703cf075c.zip
Diffstat (limited to '')
-rw-r--r--applypatch/applypatch.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/applypatch/applypatch.cpp b/applypatch/applypatch.cpp
index f9383ddeb..90d8e8604 100644
--- a/applypatch/applypatch.cpp
+++ b/applypatch/applypatch.cpp
@@ -76,7 +76,7 @@ static bool ReadPartitionToBuffer(const Partition& partition, FileContents* out,
}
android::base::unique_fd dev(open(partition.name.c_str(), O_RDONLY));
- if (!dev) {
+ if (dev == -1) {
PLOG(ERROR) << "Failed to open eMMC partition \"" << partition << "\"";
} else {
std::vector<unsigned char> buffer(partition.size);