mount-util: mount flag is unsigned long

This commit is contained in:
Yu Watanabe
2022-12-14 14:58:48 +09:00
parent b8b4f80a8a
commit 6c6eb219d5
2 changed files with 3 additions and 4 deletions

View File

@@ -439,7 +439,7 @@ static const char *const mount_attr_propagation_type_table[_MOUNT_ATTR_PROPAGATI
DEFINE_STRING_TABLE_LOOKUP(mount_attr_propagation_type, MountAttrPropagationType);
unsigned int mount_attr_propagation_type_to_flag(MountAttrPropagationType t) {
static unsigned long mount_attr_propagation_type_to_flag(MountAttrPropagationType t) {
switch (t) {
case MOUNT_ATTR_PROPAGATION_INHERIT:
return 0;
@@ -498,9 +498,9 @@ static int mount_switch_root_move(const char *path) {
}
int mount_switch_root(const char *path, MountAttrPropagationType type) {
int r;
_cleanup_close_ int fd_newroot = -EBADF;
unsigned int flags;
unsigned long flags;
int r;
assert(path);

View File

@@ -23,7 +23,6 @@ typedef enum MountAttrPropagationType {
const char* mount_attr_propagation_type_to_string(MountAttrPropagationType t) _const_;
MountAttrPropagationType mount_attr_propagation_type_from_string(const char *s) _pure_;
unsigned int mount_attr_propagation_type_to_flag(MountAttrPropagationType t);
int repeat_unmount(const char *path, int flags);
int umount_recursive(const char *target, int flags);