chiark / gitweb /
rm-rf: make flags fields easier to read
authorLennart Poettering <lennart@poettering.net>
Fri, 9 Feb 2018 08:52:36 +0000 (09:52 +0100)
committerSven Eden <yamakuzure@gmx.net>
Wed, 30 May 2018 05:58:53 +0000 (07:58 +0200)
src/basic/rm-rf.h

index 3ff1f1a1b2aebd33068d761ee9ab285005f5eb5f..27d8cc1e55a8f390184db5f250a276e43923ebe3 100644 (file)
 //#include "util.h"
 
 typedef enum RemoveFlags {
-        REMOVE_ONLY_DIRECTORIES = 1,
-        REMOVE_ROOT = 2,
-        REMOVE_PHYSICAL = 4, /* if not set, only removes files on tmpfs, never physical file systems */
-        REMOVE_SUBVOLUME = 8,
+        REMOVE_ONLY_DIRECTORIES = 1 << 0,
+        REMOVE_ROOT             = 1 << 1,
+        REMOVE_PHYSICAL         = 1 << 2, /* if not set, only removes files on tmpfs, never physical file systems */
+        REMOVE_SUBVOLUME        = 1 << 3,
 } RemoveFlags;
 
 int rm_rf_children(int fd, RemoveFlags flags, struct stat *root_dev);