From 8bc655f014eeb24bf52ffc83e0b8ae9d987569d5 Mon Sep 17 00:00:00 2001 From: Francis Rowe Date: Sat, 13 Jun 2015 15:52:26 +0100 Subject: flashing script: fix broken if/else chain --- flash | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/flash b/flash index 97ff9363..eb1fc92e 100755 --- a/flash +++ b/flash @@ -55,12 +55,12 @@ if [ $# -lt 2 ]; then fi # User specified an invalid mode of operation -if [ "${1}" = "update" ] || [ "${1}" = "forceupdate" ] || [ "${1}" = "i945lenovo_firstflash" ] || [ "${1}" != "i945lenovo_secondflash" ] || [ "${1}" != "i945apple_firstflash" ]; then - printf "Mode selected: %s\n" "${1}" -else +if [ "${1}" != "update" ] && [ "${1}" != "forceupdate" ] && [ "${1}" != "i945lenovo_firstflash" ] && [ "${1}" != "i945lenovo_secondflash" ] && [ "${1}" != "i945apple_firstflash" ]; then printf "%s\n" "${usage}" printf "Invalid mode. Modes available: %s\n" "${availablemodes}" exit 1 +else + printf "Mode selected: %s\n" "${1}" fi # The specified file does not exist -- cgit v1.2.3-70-g09d2