diff options
author | Namyoon Woo <namyoon@chromium.org> | 2019-06-21 08:41:48 -0700 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2019-06-22 03:37:42 +0000 |
commit | 260230523897331d9a36e48a6ff993a192f9af86 (patch) | |
tree | 6621325153481423e39645130ba66b0a9acc9524 /util | |
parent | 3f80f258a4aad6a7ec048683586e0ecb6c122faf (diff) | |
download | chrome-ec-260230523897331d9a36e48a6ff993a192f9af86.tar.gz |
flash_ec: fix in returning the error code 1 for missing temp file
When flashing ec with servo_micro, though it was successful,
flash returned 1 at the end. It was from an attemp to delete temp
files, which do exist at all.
This patch makes it tolerant.
BUG=chromium:977240
BRANCH=None
TEST=manually ran on Atlas
Change-Id: I48f4d256cb7e98e9762d4821db48fbbbdfb94815
Signed-off-by: Namyoon Woo <namyoon@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1670844
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Diffstat (limited to 'util')
-rwxr-xr-x | util/flash_ec | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/util/flash_ec b/util/flash_ec index 5199758e12..955a0d884b 100755 --- a/util/flash_ec +++ b/util/flash_ec @@ -889,8 +889,8 @@ function flash_flashrom() { ${FLASHROM_CMDLINE} -v "${T}" fi - [[ -f "${T}" ]] && rm "${T}" - [[ -f "${L}" ]] && rm "${L}" + [[ -f "${T}" ]] && rm "${T}" || true + [[ -f "${L}" ]] && rm "${L}" || true } function flash_stm32() { |