All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [Bug 1643537] [NEW] target-ppc/int_helper.c: 2 * bad array index
@ 2016-11-21 12:16 dcb
  2016-11-21 13:23 ` Thomas Huth
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: dcb @ 2016-11-21 12:16 UTC (permalink / raw)
  To: qemu-devel

Public bug reported:

1.

[qemu/target-ppc/int_helper.c:2575]: (error) Array 'reg.u16[8]' accessed
at index 8, which is out of bounds.

Source code is

   return reg->u16[8 - n];

and

qemu/target-ppc/cpu.h:    uint16_t u16[8];

but at least once, n is zero, for example line 2725 in the int_helper.c
file:

    uint16_t sgnb = get_national_digit(b, 0);

2.

[qemu/target-ppc/int_helper.c:2584]: (error) Array 'reg.u16[8]' accessed
at index 8, which is out of bounds.

Duplicate

** Affects: qemu
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1643537

Title:
  target-ppc/int_helper.c: 2 * bad array index

Status in QEMU:
  New

Bug description:
  1.

  [qemu/target-ppc/int_helper.c:2575]: (error) Array 'reg.u16[8]'
  accessed at index 8, which is out of bounds.

  Source code is

     return reg->u16[8 - n];

  and

  qemu/target-ppc/cpu.h:    uint16_t u16[8];

  but at least once, n is zero, for example line 2725 in the
  int_helper.c file:

      uint16_t sgnb = get_national_digit(b, 0);

  2.

  [qemu/target-ppc/int_helper.c:2584]: (error) Array 'reg.u16[8]'
  accessed at index 8, which is out of bounds.

  Duplicate

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1643537/+subscriptions

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Qemu-devel] [Bug 1643537] [NEW] target-ppc/int_helper.c: 2 * bad array index
  2016-11-21 12:16 [Qemu-devel] [Bug 1643537] [NEW] target-ppc/int_helper.c: 2 * bad array index dcb
@ 2016-11-21 13:23 ` Thomas Huth
  2016-11-21 14:58   ` joserz
  2016-11-21 15:15 ` [Qemu-devel] [Bug 1643537] " Thomas Huth
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 6+ messages in thread
From: Thomas Huth @ 2016-11-21 13:23 UTC (permalink / raw)
  To: Bug 1643537, qemu-devel, Jose Ricardo Ziviani; +Cc: qemu-ppc

On 21.11.2016 13:16, dcb wrote:
> Public bug reported:
> 
> 1.
> 
> [qemu/target-ppc/int_helper.c:2575]: (error) Array 'reg.u16[8]' accessed
> at index 8, which is out of bounds.
> 
> Source code is
> 
>    return reg->u16[8 - n];
> 
> and
> 
> qemu/target-ppc/cpu.h:    uint16_t u16[8];
> 
> but at least once, n is zero, for example line 2725 in the int_helper.c
> file:
> 
>     uint16_t sgnb = get_national_digit(b, 0);

That looks wrong, indeed. I guess it should be "7 - n" instead of
"8 - n"? Jose, could you please have a look at this?

 Thomas

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Qemu-devel] [Bug 1643537] [NEW] target-ppc/int_helper.c: 2 * bad array index
  2016-11-21 13:23 ` Thomas Huth
@ 2016-11-21 14:58   ` joserz
  0 siblings, 0 replies; 6+ messages in thread
From: joserz @ 2016-11-21 14:58 UTC (permalink / raw)
  To: Thomas Huth; +Cc: Bug 1643537, qemu-devel, qemu-ppc

On Mon, Nov 21, 2016 at 02:23:25PM +0100, Thomas Huth wrote:
> On 21.11.2016 13:16, dcb wrote:
> > Public bug reported:
> > 
> > 1.
> > 
> > [qemu/target-ppc/int_helper.c:2575]: (error) Array 'reg.u16[8]' accessed
> > at index 8, which is out of bounds.
> > 
> > Source code is
> > 
> >    return reg->u16[8 - n];
> > 
> > and
> > 
> > qemu/target-ppc/cpu.h:    uint16_t u16[8];
> > 
> > but at least once, n is zero, for example line 2725 in the int_helper.c
> > file:
> > 
> >     uint16_t sgnb = get_national_digit(b, 0);
> 
> That looks wrong, indeed. I guess it should be "7 - n" instead of
> "8 - n"? Jose, could you please have a look at this?
> 
>  Thomas
> 
Hello Thomas,

Just sent a patch to address it.

Thanks for letting me know it.

Ziviani

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Qemu-devel] [Bug 1643537] Re: target-ppc/int_helper.c: 2 * bad array index
  2016-11-21 12:16 [Qemu-devel] [Bug 1643537] [NEW] target-ppc/int_helper.c: 2 * bad array index dcb
  2016-11-21 13:23 ` Thomas Huth
@ 2016-11-21 15:15 ` Thomas Huth
  2016-12-07  8:40 ` Thomas Huth
  2017-01-16 11:37 ` Thomas Huth
  3 siblings, 0 replies; 6+ messages in thread
From: Thomas Huth @ 2016-11-21 15:15 UTC (permalink / raw)
  To: qemu-devel

Thanks for the bug report! Jose posted a patch:
marc.info/?i=1479740113-26834-1-git-send-email-joserz@linux.vnet.ibm.com

** Changed in: qemu
       Status: New => Confirmed

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1643537

Title:
  target-ppc/int_helper.c: 2 * bad array index

Status in QEMU:
  Confirmed

Bug description:
  1.

  [qemu/target-ppc/int_helper.c:2575]: (error) Array 'reg.u16[8]'
  accessed at index 8, which is out of bounds.

  Source code is

     return reg->u16[8 - n];

  and

  qemu/target-ppc/cpu.h:    uint16_t u16[8];

  but at least once, n is zero, for example line 2725 in the
  int_helper.c file:

      uint16_t sgnb = get_national_digit(b, 0);

  2.

  [qemu/target-ppc/int_helper.c:2584]: (error) Array 'reg.u16[8]'
  accessed at index 8, which is out of bounds.

  Duplicate

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1643537/+subscriptions

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Qemu-devel] [Bug 1643537] Re: target-ppc/int_helper.c: 2 * bad array index
  2016-11-21 12:16 [Qemu-devel] [Bug 1643537] [NEW] target-ppc/int_helper.c: 2 * bad array index dcb
  2016-11-21 13:23 ` Thomas Huth
  2016-11-21 15:15 ` [Qemu-devel] [Bug 1643537] " Thomas Huth
@ 2016-12-07  8:40 ` Thomas Huth
  2017-01-16 11:37 ` Thomas Huth
  3 siblings, 0 replies; 6+ messages in thread
From: Thomas Huth @ 2016-12-07  8:40 UTC (permalink / raw)
  To: qemu-devel

Fix has been committed:
http://git.qemu.org/?p=qemu.git;a=commitdiff;h=a813fe73621e1221a09

** Changed in: qemu
       Status: Confirmed => Fix Committed

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1643537

Title:
  target-ppc/int_helper.c: 2 * bad array index

Status in QEMU:
  Fix Committed

Bug description:
  1.

  [qemu/target-ppc/int_helper.c:2575]: (error) Array 'reg.u16[8]'
  accessed at index 8, which is out of bounds.

  Source code is

     return reg->u16[8 - n];

  and

  qemu/target-ppc/cpu.h:    uint16_t u16[8];

  but at least once, n is zero, for example line 2725 in the
  int_helper.c file:

      uint16_t sgnb = get_national_digit(b, 0);

  2.

  [qemu/target-ppc/int_helper.c:2584]: (error) Array 'reg.u16[8]'
  accessed at index 8, which is out of bounds.

  Duplicate

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1643537/+subscriptions

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Qemu-devel] [Bug 1643537] Re: target-ppc/int_helper.c: 2 * bad array index
  2016-11-21 12:16 [Qemu-devel] [Bug 1643537] [NEW] target-ppc/int_helper.c: 2 * bad array index dcb
                   ` (2 preceding siblings ...)
  2016-12-07  8:40 ` Thomas Huth
@ 2017-01-16 11:37 ` Thomas Huth
  3 siblings, 0 replies; 6+ messages in thread
From: Thomas Huth @ 2017-01-16 11:37 UTC (permalink / raw)
  To: qemu-devel

Released with version 2.8

** Changed in: qemu
       Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1643537

Title:
  target-ppc/int_helper.c: 2 * bad array index

Status in QEMU:
  Fix Released

Bug description:
  1.

  [qemu/target-ppc/int_helper.c:2575]: (error) Array 'reg.u16[8]'
  accessed at index 8, which is out of bounds.

  Source code is

     return reg->u16[8 - n];

  and

  qemu/target-ppc/cpu.h:    uint16_t u16[8];

  but at least once, n is zero, for example line 2725 in the
  int_helper.c file:

      uint16_t sgnb = get_national_digit(b, 0);

  2.

  [qemu/target-ppc/int_helper.c:2584]: (error) Array 'reg.u16[8]'
  accessed at index 8, which is out of bounds.

  Duplicate

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1643537/+subscriptions

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-01-16 11:50 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-21 12:16 [Qemu-devel] [Bug 1643537] [NEW] target-ppc/int_helper.c: 2 * bad array index dcb
2016-11-21 13:23 ` Thomas Huth
2016-11-21 14:58   ` joserz
2016-11-21 15:15 ` [Qemu-devel] [Bug 1643537] " Thomas Huth
2016-12-07  8:40 ` Thomas Huth
2017-01-16 11:37 ` Thomas Huth

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.