From: Cathy Avery Date: Thu, 12 Jul 2012 13:45:08 +0000 (-0400) Subject: Changed length for strncpy to OVMM_MAX_NAME_LEN X-Git-Tag: v2.6.39-400.9.0~491 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=e950078be8d508575695b4f0cb8eab19e77d79a5;p=users%2Fjedix%2Flinux-maple.git Changed length for strncpy to OVMM_MAX_NAME_LEN Orabug: 14233627 This is the fix for Oracle Bug 14233627 Signed-off-by: Cathy Avery --- diff --git a/drivers/xen/ovmapi.c b/drivers/xen/ovmapi.c index d3a64afe5053..cc325a3c444d 100644 --- a/drivers/xen/ovmapi.c +++ b/drivers/xen/ovmapi.c @@ -983,7 +983,7 @@ static long ovmapi_ioctl(struct file *file, unsigned int cmd, if (!name) return -ENOMEM; value = kmalloc(message.value_size, GFP_ATOMIC); - strncpy(name, message.name, message.value_size); + strncpy(name, message.name,OVMM_MAX_NAME_LEN); if (copy_from_user(value, message.value, message.value_size)) return -EFAULT; status = ovmapi_send_dom0_message(&ovmapi_info, name, value, @@ -1001,6 +1001,7 @@ static long ovmapi_ioctl(struct file *file, unsigned int cmd, return -EINVAL; status = ovmapi_delete_parameter(&ovmapi_info, argp); return status; + case IOCTL_XENPCI_POST_EVENT: if (!arg) return -EINVAL;