diff options
author | Matt Mower <mowerm@gmail.com> | 2017-02-12 22:13:00 +0100 |
---|---|---|
committer | Dees Troy <dees_troy@teamw.in> | 2017-02-16 05:19:59 +0100 |
commit | 6244806a628a24e95e389616aa849d96e1010e62 (patch) | |
tree | 574a1e22bada4c00034a58ba8657c52784925b43 | |
parent | DE language update (diff) | |
download | android_bootable_recovery-6244806a628a24e95e389616aa849d96e1010e62.tar android_bootable_recovery-6244806a628a24e95e389616aa849d96e1010e62.tar.gz android_bootable_recovery-6244806a628a24e95e389616aa849d96e1010e62.tar.bz2 android_bootable_recovery-6244806a628a24e95e389616aa849d96e1010e62.tar.lz android_bootable_recovery-6244806a628a24e95e389616aa849d96e1010e62.tar.xz android_bootable_recovery-6244806a628a24e95e389616aa849d96e1010e62.tar.zst android_bootable_recovery-6244806a628a24e95e389616aa849d96e1010e62.zip |
-rw-r--r-- | bootloader_message/bootloader_message.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/bootloader_message/bootloader_message.cpp b/bootloader_message/bootloader_message.cpp index 449f40e11..4d1ce5bb4 100644 --- a/bootloader_message/bootloader_message.cpp +++ b/bootloader_message/bootloader_message.cpp @@ -159,10 +159,7 @@ static bool write_misc_partition(const void* p, size_t size, size_t offset, std: *err = "no misc device set"; return false; } - int open_flags = O_WRONLY | O_SYNC; - if (offset > 0) - open_flags = O_RDWR | O_APPEND | O_SYNC; - int fd = (open(misc_blk_device.c_str(), open_flags)); + int fd = (open(misc_blk_device.c_str(), O_WRONLY | O_SYNC)); if (fd == -1) { *err = "failed to open " + misc_blk_device + ": "; *err += strerror(errno); |