Skip to content

Commit

Permalink
Update 400_save_directories.sh
Browse files Browse the repository at this point in the history
Addendum to 7c26f94
add a comment that the current code still fails when
the symlink or its target contain special characters,
cf. #1372
  • Loading branch information
jsmeix committed May 29, 2020
1 parent 0af7bbc commit bf37459
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions usr/share/rear/prep/default/400_save_directories.sh
Expand Up @@ -72,6 +72,8 @@ for directoryglob in $FHSdirectories ; do
# '/var/mail' -> 'spool/mail'
# so we remove the characters ' and ` (octal \047 and \140) to get plain
# /var/mail -> spool/mail
# FIXME: This code fails when the symlink or its target contains special characters
# cf. https://github.com/rear/rear/issues/1372
stat -c '%N' "$directory" | tr -d '\047\140' >>"$directories_permissions_owner_group_file"
# Symbolic links are output like (e.g. on a SLES12 system)
# note the difference between absolute and relative symbolic link target:
Expand Down

0 comments on commit bf37459

Please sign in to comment.