Btrfs: send: fix error number for unknown inode types
authorTsutomu Itoh <t-itoh@jp.fujitsu.com>
Fri, 22 Jan 2016 00:13:25 +0000 (09:13 +0900)
committerDavid Sterba <dsterba@suse.com>
Tue, 26 Sep 2017 12:52:06 +0000 (14:52 +0200)
ENOTSUPP should not be returned to the user program.
 (cf. include/linux/errno.h)
Therefore, EOPNOTSUPP is used instead of ENOTSUPP.

Signed-off-by: Tsutomu Itoh <t-itoh@jp.fujitsu.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/send.c

index 8f1d3d6..43430e6 100644 (file)
@@ -2640,7 +2640,7 @@ static int send_create_inode(struct send_ctx *sctx, u64 ino)
        } else {
                btrfs_warn(sctx->send_root->fs_info, "unexpected inode type %o",
                                (int)(mode & S_IFMT));
-               ret = -ENOTSUPP;
+               ret = -EOPNOTSUPP;
                goto out;
        }