From: Adam Michalski Date: Fri, 28 Jul 2023 11:05:34 +0000 (+0200) Subject: Support for mount unit filenames containing a dash X-Git-Tag: accepted/tizen/unified/20230825.044301~8 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F73%2F296473%2F6;p=platform%2Fcore%2Fsystem%2Fisu.git Support for mount unit filenames containing a dash A mount unit file having a dash in its name must be escaped. Change-Id: I051489c876ffa9eca73ea8b5e63598033e62feb4 --- diff --git a/src/systemd_generator/isu-generator b/src/systemd_generator/isu-generator index c44d6bc..e245140 100755 --- a/src/systemd_generator/isu-generator +++ b/src/systemd_generator/isu-generator @@ -50,7 +50,7 @@ install_units() cp -a "$SERVICES_DIR/${srv_fname}" "$UNITDIR/nonisu-${srv_fname}" || return 1 # 2nd step: generate mount unit for ISU image and extend the service file to use it - local mount_unit="run-isu-${isu_pkg_name}-rootfs.mount" + local mount_unit="run-isu-$(systemd-escape ${isu_pkg_name})-rootfs.mount" cat <> "$UNITDIR/$mount_unit" || return 1 # This unit file has been automatically generated by isu-generator. #