stdenv: added escaping for patches
This commit is contained in:
parent
d15e52f25f
commit
d59327b938
@ -569,12 +569,12 @@ patchPhase() {
|
|||||||
|
|
||||||
for i in $patches; do
|
for i in $patches; do
|
||||||
header "applying patch $i" 3
|
header "applying patch $i" 3
|
||||||
if [ ! -r $i ]; then
|
if [ ! -r "$i" ]; then
|
||||||
echo "file $i does not exist or not readable"
|
echo "file $i does not exist or not readable"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
local uncompress=cat
|
local uncompress=cat
|
||||||
case $i in
|
case "$i" in
|
||||||
*.gz)
|
*.gz)
|
||||||
uncompress="gzip -d"
|
uncompress="gzip -d"
|
||||||
;;
|
;;
|
||||||
@ -589,7 +589,7 @@ patchPhase() {
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
# "2>&1" is a hack to make patch fail if the decompressor fails (nonexistent patch, etc.)
|
# "2>&1" is a hack to make patch fail if the decompressor fails (nonexistent patch, etc.)
|
||||||
$uncompress < $i 2>&1 | patch ${patchFlags:--p1}
|
$uncompress < "$i" 2>&1 | patch ${patchFlags:--p1}
|
||||||
stopNest
|
stopNest
|
||||||
done
|
done
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user