summaryrefslogtreecommitdiffstats
path: root/drivers/md/dm-snap-persistent.c
diff options
context:
space:
mode:
authorNikanth Karthikesan <knikanth@suse.de>2010-02-16 19:42:47 +0100
committerAlasdair G Kergon <agk@redhat.com>2010-02-16 19:42:47 +0100
commit781248c1b50c776a9ef4be1130f84ced1cba42fe (patch)
treeaa102797cde7b10623eefbeee493c36fdf2bdfe3 /drivers/md/dm-snap-persistent.c
parentMerge git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable (diff)
downloadlinux-781248c1b50c776a9ef4be1130f84ced1cba42fe.tar.xz
linux-781248c1b50c776a9ef4be1130f84ced1cba42fe.zip
dm stripe: avoid divide by zero with invalid stripe count
If a table containing zero as stripe count is passed into stripe_ctr the code attempts to divide by zero. This patch changes DM_TABLE_LOAD to return -EINVAL if the stripe count is zero. We now get the following error messages: device-mapper: table: 253:0: striped: Invalid stripe count device-mapper: ioctl: error adding target to table Signed-off-by: Nikanth Karthikesan <knikanth@suse.de> Cc: stable@kernel.org Signed-off-by: Alasdair G Kergon <agk@redhat.com>
Diffstat (limited to 'drivers/md/dm-snap-persistent.c')
0 files changed, 0 insertions, 0 deletions