mirror of
https://github.com/isc-projects/bind9.git
synced 2026-04-26 00:30:05 -04:00
2369. [bug] libbind: Array bounds overrun on read in bitncmp().
[RT #18054]
This commit is contained in:
parent
6fbe9050cb
commit
e1aeb1569a
2 changed files with 5 additions and 2 deletions
3
CHANGES
3
CHANGES
|
|
@ -1,3 +1,6 @@
|
|||
2369. [bug] libbind: Array bounds overrun on read in bitncmp().
|
||||
[RT #18054]
|
||||
|
||||
2368. [port] Linux: use libcap for capability management if
|
||||
possible. [RT# 18026]
|
||||
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@
|
|||
*/
|
||||
|
||||
#if defined(LIBC_SCCS) && !defined(lint)
|
||||
static const char rcsid[] = "$Id: bitncmp.c,v 1.3 2005/04/27 04:56:35 sra Exp $";
|
||||
static const char rcsid[] = "$Id: bitncmp.c,v 1.4 2008/05/12 00:17:27 marka Exp $";
|
||||
#endif
|
||||
|
||||
#include "port_before.h"
|
||||
|
|
@ -48,7 +48,7 @@ bitncmp(const void *l, const void *r, int n) {
|
|||
|
||||
b = n / 8;
|
||||
x = memcmp(l, r, b);
|
||||
if (x)
|
||||
if (x || (n % 8) == 0)
|
||||
return (x);
|
||||
|
||||
lb = ((const u_char *)l)[b];
|
||||
|
|
|
|||
Loading…
Reference in a new issue