mirror of
https://github.com/hackacad/bastille.git
synced 2026-01-03 19:23:42 +01:00
cp: trim double // to /
This commit is contained in:
@@ -89,8 +89,9 @@ set_target "${TARGET}"
|
||||
|
||||
for _jail in ${JAILS}; do
|
||||
info "[${_jail}]:"
|
||||
bastille_jail_path="${bastille_jailsdir}/${_jail}/root"
|
||||
if ! cp "${OPTION}" "${CPSOURCE}" "${bastille_jail_path}${CPDEST}"; then
|
||||
error_continue "CP failed: ${CPSOURCE} -> ${bastille_jail_path}${CPDEST}"
|
||||
host_path="${CPSOURCE}"
|
||||
jail_path="$(echo ${bastille_jailsdir}/${_jail}/root/${CPDEST} | sed 's#//#/#g')"
|
||||
if ! cp "${OPTION}" "${host_path}" "${jail_path}"; then
|
||||
error_continue "CP failed: ${host_path} -> ${jail_path}"
|
||||
fi
|
||||
done
|
||||
|
||||
Reference in New Issue
Block a user