mkfs.ubifs: ignore EOPNOTSUPP when listing extended attributes

Message ID 20171024150730.5787-1-plroskin@gmail.com
State New
Delegated to: Richard Weinberger
Headers show
Series
  • mkfs.ubifs: ignore EOPNOTSUPP when listing extended attributes
Related show

Commit Message

Pavel Roskin Oct. 24, 2017, 3:07 p.m.
Systems that don't support extended attributes should still be able to
create ubifs images.

Signed-off-by: Pavel Roskin <plroskin@gmail.com>
---
 ubifs-utils/mkfs.ubifs/mkfs.ubifs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

David Oberhollenzer Oct. 30, 2017, 11:16 a.m. | #1
Applied to mtd-utils.git

Thanks,

David

Patch

diff --git a/ubifs-utils/mkfs.ubifs/mkfs.ubifs.c b/ubifs-utils/mkfs.ubifs/mkfs.ubifs.c
index d432dfe..c916f48 100644
--- a/ubifs-utils/mkfs.ubifs/mkfs.ubifs.c
+++ b/ubifs-utils/mkfs.ubifs/mkfs.ubifs.c
@@ -1128,7 +1128,7 @@  static int inode_add_xattr(struct ubifs_ino_node *host_ino,
 
 	len = llistxattr(path_name, NULL, 0);
 	if (len < 0) {
-		if (errno == ENOENT)
+		if (errno == ENOENT || errno == EOPNOTSUPP)
 			return 0;
 
 		sys_err_msg("llistxattr failed on %s", path_name);