[med_integrity] Fixed fileList generation
This commit is contained in:
parent
aa07cc1da8
commit
c8ff189143
1 changed files with 4 additions and 2 deletions
|
@ -13,12 +13,14 @@
|
||||||
# }
|
# }
|
||||||
|
|
||||||
med_integrity() {
|
med_integrity() {
|
||||||
local FILE="${1}"
|
local fileList=(${@})
|
||||||
|
|
||||||
for file in ${fileList[@]}; do
|
for file in ${fileList[@]}; do
|
||||||
flac -wst "${file}" >${STDERR} 2>&1
|
flac -wst "${file}" >${STDERR} 2>&1
|
||||||
local EXIT=$?
|
|
||||||
[[ $? -eq 0 ]] || { echo "[>>>>>>] Error reported"; cat ${STDERR}; local ERR=true; }
|
[[ $? -eq 0 ]] || { echo "[>>>>>>] Error reported"; cat ${STDERR}; local ERR=true; }
|
||||||
done
|
done
|
||||||
|
echo >${STDERR}
|
||||||
[[ "${ERR}" == "true" ]] && { _msg EXEC "Integrity check completed with errors"; _msg WARN; return 1; } || { _msg EXEC "Integrity check completed succesfully"; _msg OK; return 0; }
|
[[ "${ERR}" == "true" ]] && { _msg EXEC "Integrity check completed with errors"; _msg WARN; return 1; } || { _msg EXEC "Integrity check completed succesfully"; _msg OK; return 0; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue