UBI: fix volume creation input checking
authorMika Westerberg <ext-mika.1.westerberg@nokia.com>
Tue, 26 Jan 2010 15:47:05 +0000 (17:47 +0200)
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Wed, 27 Jan 2010 09:55:43 +0000 (11:55 +0200)
Do not use an unchecked variable UBI_IOCMKVOL ioctl.

Signed-off-by: Mika Westerberg <ext-mika.1.westerberg@nokia.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Cc: stable@vger.kernel.org
drivers/mtd/ubi/cdev.c

index f237ddbb271307f8252c3582506b1f32b4c13f98..111ea41c4ecd7aa956be1f21c26d775dc68270e4 100644 (file)
@@ -853,7 +853,6 @@ static long ubi_cdev_ioctl(struct file *file, unsigned int cmd,
                        break;
                }
 
-               req.name[req.name_len] = '\0';
                err = verify_mkvol_req(ubi, &req);
                if (err)
                        break;