Remove dead selinux code
[project/make_ext4fs.git] / make_ext4fs.c
index bc63236..fc1802b 100644 (file)
@@ -242,16 +242,6 @@ static u32 build_directory_structure(const char *full_path, const char *dir_path
                if (ret)
                        error("failed to set permissions on %s\n", dentries[i].path);
 
-               /*
-                * It's important to call inode_set_selinux() before
-                * inode_set_capabilities(). Extended attributes need to
-                * be stored sorted order, and we guarantee this by making
-                * the calls in the proper order.
-                * Please see xattr_assert_sane() in contents.c
-                */
-               ret = inode_set_selinux(entry_inode, dentries[i].secon);
-               if (ret)
-                       error("failed to set SELinux context on %s\n", dentries[i].path);
                ret = inode_set_capabilities(entry_inode, dentries[i].capabilities);
                if (ret)
                        error("failed to set capability on %s\n", dentries[i].path);
@@ -260,7 +250,6 @@ static u32 build_directory_structure(const char *full_path, const char *dir_path
                free(dentries[i].full_path);
                free(dentries[i].link);
                free((void *)dentries[i].filename);
-               free(dentries[i].secon);
        }
 
        free(dentries);