aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Kaspar [Dee'Kej] <dkaspar@redhat.com>2016-08-30 13:51:27 +0200
committerDavid Kaspar [Dee'Kej] <dkaspar@redhat.com>2016-08-30 13:51:27 +0200
commitb74933e6d4642f1864bf78855b3d61be6349312f (patch)
tree7cdd60263e1ec1db9fa08259f99bac84bd765fa5
parent416a36b32141168d432aadf6fd05b9878e94c66a (diff)
downloadinitscripts-b74933e6d4642f1864bf78855b3d61be6349312f.tar
initscripts-b74933e6d4642f1864bf78855b3d61be6349312f.tar.gz
initscripts-b74933e6d4642f1864bf78855b3d61be6349312f.tar.bz2
initscripts-b74933e6d4642f1864bf78855b3d61be6349312f.tar.xz
initscripts-b74933e6d4642f1864bf78855b3d61be6349312f.zip
fedora-import-state: do not try to create folder with empty name
Resolves: #1370259
-rwxr-xr-xsystemd/fedora-import-state2
1 files changed, 1 insertions, 1 deletions
diff --git a/systemd/fedora-import-state b/systemd/fedora-import-state
index c34ad0f8..16447026 100755
--- a/systemd/fedora-import-state
+++ b/systemd/fedora-import-state
@@ -17,7 +17,7 @@ for dir in $dirs_found; do
dest_dir="${dir/\./}"
# Create destination folder if it does not exist (with the same rights):
- if ! [[ -d "$dest_dir" ]]; then
+ if [[ -n "$dest_dir" && ! -d "$dest_dir" ]]; then
mkdir -p "$dest_dir"
chmod --reference="$PWD" "$dest_dir"
chown --reference="$PWD" "$dest_dir"