Bug 1837939 - update-packaging: quote filenames that can contain spaces. r=releng-reviewers,bhearsum DONTBUILD

Bug 1837329 added a new "Media Plugin Helper" that caused errors in repack logs
(though as far as I can tell had no effect on the mar files themselves).

Differential Revision: https://phabricator.services.mozilla.com/D180669
This commit is contained in:
Julien Cristau 2023-06-12 13:14:53 +00:00
parent 5ff695c8b3
commit 40e11b8360
3 changed files with 7 additions and 7 deletions

View file

@ -92,8 +92,8 @@ make_add_instruction() {
check_for_add_if_not_update() {
add_if_not_file_chk="$1"
if [ `basename $add_if_not_file_chk` = "channel-prefs.js" -o \
`basename $add_if_not_file_chk` = "update-settings.ini" ]; then
if [ "$(basename "$add_if_not_file_chk")" = "channel-prefs.js" -o \
"$(basename "$add_if_not_file_chk")" = "update-settings.ini" ]; then
## "true" *giggle*
return 0;
fi

View file

@ -166,7 +166,7 @@ for ((i=0; $i<$num_oldfiles; i=$i+1)); do
if check_for_add_if_not_update "$f"; then
# The full workdir may not exist yet, so create it if necessary.
mkdir -p `dirname "$workdir/$f"`
mkdir -p "$(dirname "$workdir/$f")"
$XZ $XZ_OPT --compress $BCJ_OPTIONS --lzma2 --format=xz --check=crc64 --force --stdout "$newdir/$f" > "$workdir/$f"
copy_perm "$newdir/$f" "$workdir/$f"
make_add_if_not_instruction "$f" "$updatemanifestv3"
@ -176,7 +176,7 @@ for ((i=0; $i<$num_oldfiles; i=$i+1)); do
if check_for_forced_update "$requested_forced_updates" "$f"; then
# The full workdir may not exist yet, so create it if necessary.
mkdir -p `dirname "$workdir/$f"`
mkdir -p "$(dirname "$workdir/$f")"
$XZ $XZ_OPT --compress $BCJ_OPTIONS --lzma2 --format=xz --check=crc64 --force --stdout "$newdir/$f" > "$workdir/$f"
copy_perm "$newdir/$f" "$workdir/$f"
make_add_instruction "$f" "$updatemanifestv3" 1

View file

@ -77,8 +77,8 @@ make_add_instruction() {
check_for_add_if_not_update() {
add_if_not_file_chk="$1"
if [ `basename $add_if_not_file_chk` = "channel-prefs.js" -o \
`basename $add_if_not_file_chk` = "update-settings.ini" ]; then
if [ "$(basename "$add_if_not_file_chk")" = "channel-prefs.js" -o \
"$(basename "$add_if_not_file_chk")" = "update-settings.ini" ]; then
## "true" *giggle*
return 0;
fi
@ -89,7 +89,7 @@ check_for_add_if_not_update() {
check_for_add_to_manifestv2() {
add_if_not_file_chk="$1"
if [ `basename $add_if_not_file_chk` = "update-settings.ini" ]; then
if [ "$(basename "$add_if_not_file_chk")" = "update-settings.ini" ]; then
## "true" *giggle*
return 0;
fi