]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit - io/reflink.c
xfs_io: allow zero-length reflink/dedupe commands
authorDarrick J. Wong <darrick.wong@oracle.com>
Fri, 18 Dec 2015 01:18:48 +0000 (12:18 +1100)
committerDave Chinner <david@fromorbit.com>
Fri, 18 Dec 2015 01:18:48 +0000 (12:18 +1100)
commitab001d6c4822f2a1a55fd30c4cce09beecb2a967
tree315be1bffdcbf7ed3f74335598763ef671c2c64a
parentbb2f98b78f20f4abbfbbd442162d9f535c84888a
xfs_io: allow zero-length reflink/dedupe commands

Since it's convention that calling the reflink/dedupe ioctls with
a zero length means "do this until you hit EOF in the source file",
explicitly permit this as an input.  Fix the ioctl code to handle
this correctly.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
io/reflink.c