diff options
author | Lennart Poettering <lennart@poettering.net> | 2015-04-04 11:52:57 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2015-04-06 10:57:53 +0200 |
commit | c6878637502b1717a110a9a7e8bba32a8583fcdf (patch) | |
tree | 44bd9f305f8f3b97a0c736c3ac549e568b6495cd /src/shared/machine-image.c | |
parent | 2f653bded321fc2271edcda43d54fcc3e6c20dc9 (diff) |
util: rework rm_rf() logic
- Move to its own file rm-rf.c
- Change parameters into a single flags parameter
- Remove "honour sticky" logic, it's unused these days
Diffstat (limited to 'src/shared/machine-image.c')
-rw-r--r-- | src/shared/machine-image.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/shared/machine-image.c b/src/shared/machine-image.c index edf986d4db..c5808af81e 100644 --- a/src/shared/machine-image.c +++ b/src/shared/machine-image.c @@ -28,6 +28,7 @@ #include "path-util.h" #include "copy.h" #include "mkdir.h" +#include "rm-rf.h" #include "machine-image.h" static const char image_search_path[] = @@ -366,7 +367,7 @@ int image_remove(Image *i) { /* fall through */ case IMAGE_RAW: - return rm_rf_dangerous(i->path, false, true, false); + return rm_rf(i->path, REMOVE_ROOT|REMOVE_PHYSICAL); default: return -EOPNOTSUPP; |