mbox series

[0/3] btrfs-progs: subvolume create: accept multiple arguments

Message ID cover.1698903010.git.wqu@suse.com (mailing list archive)
Headers show
Series btrfs-progs: subvolume create: accept multiple arguments | expand

Message

Qu Wenruo Nov. 2, 2023, 5:33 a.m. UTC
This patchset adds the ability to accept multiple arguments for "btrfs
subvolume create" command, just like "mkdir".

And also we follow the error reporting part of "mkdir", any failure
would make the command to return 1 for error.

[PATCHSET STRUCTURE]
During the development, I found two missing error handling for strdup(),
thus here comes the first patch to fix them.

Then the 2nd patch implements the main part.

Finally the last patch is add the new test case for the error handling
part.

Qu Wenruo (3):
  btrfs-progs: subvolume create: handle failure for strdup()
  btrfs-progs: subvolume create: accept multiple arguments
  btrfs-progs: cli-tests: add test case for subvolume create multiple
    arguments

 Documentation/btrfs-subvolume.rst             |  11 +-
 cmds/subvolume.c                              | 223 ++++++++++--------
 .../021-subvolume-multiple-arguments/test.sh  |  37 +++
 3 files changed, 170 insertions(+), 101 deletions(-)
 create mode 100755 tests/cli-tests/021-subvolume-multiple-arguments/test.sh

--
2.42.0

Comments

David Sterba Nov. 23, 2023, 7:22 p.m. UTC | #1
On Thu, Nov 02, 2023 at 04:03:47PM +1030, Qu Wenruo wrote:
> This patchset adds the ability to accept multiple arguments for "btrfs
> subvolume create" command, just like "mkdir".
> 
> And also we follow the error reporting part of "mkdir", any failure
> would make the command to return 1 for error.
> 
> [PATCHSET STRUCTURE]
> During the development, I found two missing error handling for strdup(),
> thus here comes the first patch to fix them.
> 
> Then the 2nd patch implements the main part.
> 
> Finally the last patch is add the new test case for the error handling
> part.
> 
> Qu Wenruo (3):
>   btrfs-progs: subvolume create: handle failure for strdup()
>   btrfs-progs: subvolume create: accept multiple arguments
>   btrfs-progs: cli-tests: add test case for subvolume create multiple
>     arguments

Added to devel, thanks.