diff options
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/snmpd/ber.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/snmpd/ber.c b/usr.sbin/snmpd/ber.c index 1b761c8eede..5765ab7c0a8 100644 --- a/usr.sbin/snmpd/ber.c +++ b/usr.sbin/snmpd/ber.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ber.c,v 1.12 2008/03/14 15:22:22 reyk Exp $ */ +/* $OpenBSD: ber.c,v 1.13 2008/03/18 14:53:07 reyk Exp $ */ /* * Copyright (c) 2007 Reyk Floeter <reyk@vantronix.net> @@ -376,7 +376,7 @@ ber_oid2ber(struct ber_oid *o, u_int8_t *buf, size_t len) v = (o->bo_id[0] * 40) + o->bo_id[1]; for (i = 2, j = 0; i <= o->bo_n; v = o->bo_id[i], i++) { for (k = 28; k >= 7; k -= 7) { - if (v > (u_int)(1 << k)) { + if (v >= (u_int)(1 << k)) { if (len) buf[j] = v >> k | BER_TAG_MORE; j++; |