[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [win-pv-devel] [PATCH] An ioctl should fail on any invalid argument



> -----Original Message-----
> From: win-pv-devel [mailto:win-pv-devel-bounces@xxxxxxxxxxxxxxxxxxxx] On
> Behalf Of Ben Chalmers
> Sent: 08 July 2016 14:37
> To: win-pv-devel@xxxxxxxxxxxxxxxxxxxx
> Cc: Ben Chalmers
> Subject: [win-pv-devel] [PATCH] An ioctl should fail on any invalid argument
> 
> Previously failures happened only if all arguments
> were invalid, leading to bugchecks if both InLen
> and OutLen were 0
> 
> Signed-off-by: Ben.Chalmers@xxxxxxxxxx

Acked-by: Paul Durrant <paul.durrant@xxxxxxxxxx>

> ---
>  src/xeniface/ioctl_gnttab.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/xeniface/ioctl_gnttab.c b/src/xeniface/ioctl_gnttab.c
> index a692f29..02e9231 100644
> --- a/src/xeniface/ioctl_gnttab.c
> +++ b/src/xeniface/ioctl_gnttab.c
> @@ -712,7 +712,7 @@ IoctlGnttabUnmapForeignPages(
>      PXENIFACE_CONTEXT_ID ContextId;
> 
>      status = STATUS_INVALID_BUFFER_SIZE;
> -    if (InLen != sizeof(XENIFACE_GNTTAB_UNMAP_FOREIGN_PAGES_IN) &&
> +    if (InLen != sizeof(XENIFACE_GNTTAB_UNMAP_FOREIGN_PAGES_IN) ||
>          OutLen != 0) {
>          goto fail1;
>      }
> --
> 2.7.0.windows.1
> 
> 
> _______________________________________________
> win-pv-devel mailing list
> win-pv-devel@xxxxxxxxxxxxxxxxxxxx
> https://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel
_______________________________________________
win-pv-devel mailing list
win-pv-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.