mirror of https://gitee.com/openkylin/linux.git
[S390] appldata: unsigned ops->size cannot be negative
unsigned ops->size cannot be negative Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
This commit is contained in:
parent
7a4a1ccd44
commit
13f8b7c5e6
|
@ -424,7 +424,7 @@ appldata_generic_handler(ctl_table *ctl, int write, struct file *filp,
|
|||
*/
|
||||
int appldata_register_ops(struct appldata_ops *ops)
|
||||
{
|
||||
if ((ops->size > APPLDATA_MAX_REC_SIZE) || (ops->size < 0))
|
||||
if (ops->size > APPLDATA_MAX_REC_SIZE)
|
||||
return -EINVAL;
|
||||
|
||||
ops->ctl_table = kzalloc(4 * sizeof(struct ctl_table), GFP_KERNEL);
|
||||
|
|
Loading…
Reference in New Issue