mirror of
https://github.com/clearlinux/swupd-server.git
synced 2026-08-19 04:57:43 +00:00
test: quote echo strings to protect against shell interpretation
Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
This commit is contained in:
@@ -87,21 +87,21 @@ gen_file_to_delta() {
|
||||
gen_file_plain() {
|
||||
local ver=$1
|
||||
local bundle=$2
|
||||
local name=$3
|
||||
local name="$3"
|
||||
|
||||
# Add plain text file into a bundle
|
||||
mkdir -p $DIR/image/$ver/$bundle
|
||||
echo $name > $DIR/image/$ver/$bundle/$name
|
||||
echo "$name" > $DIR/image/$ver/$bundle/"$name"
|
||||
}
|
||||
|
||||
gen_file_plain_change() {
|
||||
local ver=$1
|
||||
local bundle=$2
|
||||
local name=$3
|
||||
local name="$3"
|
||||
|
||||
# Add plain text file into a bundle
|
||||
mkdir -p $DIR/image/$ver/$bundle
|
||||
echo $ver $name > $DIR/image/$ver/$bundle/$name
|
||||
echo "$ver $name" > $DIR/image/$ver/$bundle/"$name"
|
||||
}
|
||||
|
||||
# vi: ft=sh ts=8 sw=2 sts=2 et tw=80
|
||||
|
||||
Reference in New Issue
Block a user