commit | 2ca4c92f58f9386e080b26f9ccd78c9ca5825a42 | [log] [tgz] |
---|---|---|
author | Alasdair G Kergon <agk@redhat.com> | Tue Aug 02 12:32:03 2011 +0100 |
committer | Alasdair G Kergon <agk@redhat.com> | Tue Aug 02 12:32:03 2011 +0100 |
tree | 638f6e97f829cdf8cfc090dabff9213dc50db149 | |
parent | 13c87583ea4e867211fc3e7edab750c353c47c95 [diff] [blame] |
dm ioctl: prevent empty message Detect invalid empty messages in core dm instead of requiring every target to check this. Signed-off-by: Alasdair G Kergon <agk@redhat.com>
diff --git a/drivers/md/dm-ioctl.c b/drivers/md/dm-ioctl.c index 4cacdad..1622a6b 100644 --- a/drivers/md/dm-ioctl.c +++ b/drivers/md/dm-ioctl.c
@@ -1402,6 +1402,11 @@ goto out; } + if (!argc) { + DMWARN("Empty message received."); + goto out; + } + table = dm_get_live_table(md); if (!table) goto out_argv;