Detect repeated values in the arch array
Repeated values in the arch array can result in architecture specific fields being repeated when using --printsrcinfo. Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
parent
e65b7d421c
commit
e767cf9a54
1 changed files with 5 additions and 0 deletions
|
@ -58,6 +58,11 @@ validate_arch() {
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if (( ${#arch[@]} != $(printf "%s\n" ${arch[@]} | sort -u | wc -l) )); then
|
||||||
|
error "$(gettext "%s can not contain duplicate values")" 'arch'
|
||||||
|
ret=1
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
lint_arch() {
|
lint_arch() {
|
||||||
|
|
Loading…
Add table
Reference in a new issue