download/coreboot: avoid variable conflict
the "board" variable in prepare_new_coreboot_tree() is also declared in fetch_coreboot_trees for the one in prepare_new_coreboot_tree, it's passed as an argument to the function, so give it a new name i learned that some shells have a global scope, when using variables of the same name between functions
This commit is contained in:
parent
0e1e9c1773
commit
c4b0825c5e
|
@ -163,13 +163,13 @@ gitclone_coreboot_from_upstream()
|
||||||
|
|
||||||
prepare_new_coreboot_tree()
|
prepare_new_coreboot_tree()
|
||||||
{
|
{
|
||||||
board=${1}
|
target=${1}
|
||||||
cbtree=${2}
|
cbtree=${2}
|
||||||
cbrevision=${3}
|
cbrevision=${3}
|
||||||
|
|
||||||
printf "Preparing coreboot tree: %s\n" ${cbtree}
|
printf "Preparing coreboot tree: %s\n" ${cbtree}
|
||||||
[ "${cbtree}" != "${board}" ] && \
|
[ "${cbtree}" != "${target}" ] && \
|
||||||
printf "(for board: %s)\n" "${board}"
|
printf "(for board: %s)\n" "${target}"
|
||||||
|
|
||||||
cp -R coreboot/coreboot "coreboot/${cbtree}" || exit 1
|
cp -R coreboot/coreboot "coreboot/${cbtree}" || exit 1
|
||||||
(
|
(
|
||||||
|
|
Loading…
Reference in a new issue