From: "Michael S. Tsirkin" <mst@redhat.com>
To: minyard@acm.org
Cc: Peter Maydell <peter.maydell@linaro.org>,
Xiao Guangrong <guangrong.xiao@linux.intel.com>,
Corey Minyard <cminyard@mvista.com>,
qemu-devel@nongnu.org, Stefan Hajnoczi <stefanha@redhat.com>,
Shannon Zhao <zhaoshenglong@huawei.com>,
Paolo Bonzini <pbonzini@redhat.com>
Subject: Re: [Qemu-devel] [PATCH 1/2] ipmi_bmc_sim: Fix off by one in check.
Date: Mon, 8 Feb 2016 12:43:04 +0200 [thread overview]
Message-ID: <20160208124255-mutt-send-email-mst@redhat.com> (raw)
In-Reply-To: <1452519152-6500-2-git-send-email-minyard@acm.org>
On Mon, Jan 11, 2016 at 07:32:31AM -0600, minyard@acm.org wrote:
> From: Corey Minyard <cminyard@mvista.com>
>
> Found by Paolo.
>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: Michael S. Tsirkin <mst@redhat.com>
> Cc: Peter Maydell <peter.maydell@linaro.org>
> Cc: Shannon Zhao <zhaoshenglong@huawei.com>
> Cc: Xiao Guangrong <guangrong.xiao@linux.intel.com>
> Cc: Stefan Hajnoczi <stefanha@redhat.com>
> Signed-off-by: Corey Minyard <cminyard@mvista.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
> ---
> hw/ipmi/ipmi_bmc_sim.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/ipmi/ipmi_bmc_sim.c b/hw/ipmi/ipmi_bmc_sim.c
> index 0a59e53..3ecf02e 100644
> --- a/hw/ipmi/ipmi_bmc_sim.c
> +++ b/hw/ipmi/ipmi_bmc_sim.c
> @@ -546,7 +546,7 @@ static void ipmi_init_sensors_from_sdrs(IPMIBmcSim *s)
> static int ipmi_register_netfn(IPMIBmcSim *s, unsigned int netfn,
> const IPMINetfn *netfnd)
> {
> - if ((netfn & 1) || (netfn > MAX_NETFNS) || (s->netfns[netfn / 2])) {
> + if ((netfn & 1) || (netfn >= MAX_NETFNS) || (s->netfns[netfn / 2])) {
> return -1;
> }
> s->netfns[netfn / 2] = netfnd;
> --
> 2.5.0
next prev parent reply other threads:[~2016-02-08 10:43 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-11 13:32 [Qemu-devel] [PATCH 0/2] A couple of IPMI bugs minyard
2016-01-11 13:32 ` [Qemu-devel] [PATCH 1/2] ipmi_bmc_sim: Fix off by one in check minyard
2016-02-08 10:43 ` Michael S. Tsirkin [this message]
2016-01-11 13:32 ` [Qemu-devel] [PATCH 2/2] ipmi_bmc_sim: Add break to correct watchdog NMI check minyard
2016-02-08 10:43 ` Michael S. Tsirkin
2016-02-08 9:14 ` [Qemu-devel] [PATCH 0/2] A couple of IPMI bugs Paolo Bonzini
2016-02-08 10:43 ` Michael S. Tsirkin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160208124255-mutt-send-email-mst@redhat.com \
--to=mst@redhat.com \
--cc=cminyard@mvista.com \
--cc=guangrong.xiao@linux.intel.com \
--cc=minyard@acm.org \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
--cc=zhaoshenglong@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.