Re: [PATCH] [v2] xen: hypercall: fix out-of-bounds memcpy

From: Nicolas Pitre
Date: Mon Feb 05 2018 - 10:51:22 EST


On Mon, 5 Feb 2018, Arnd Bergmann wrote:

> + if (cmd > ARRAY_SIZE(evtchnop_len))
> + return -ENOSYS;
> + len = evtchnop_len[cmd];

What if cmd == ARRAY_SIZE(evtchnop_len) ?


Nicolas