diff options
author | Henning Brauer <henning@cvs.openbsd.org> | 2004-04-25 18:21:19 +0000 |
---|---|---|
committer | Henning Brauer <henning@cvs.openbsd.org> | 2004-04-25 18:21:19 +0000 |
commit | 2e474eb74ee16139713346307d0b9f750bb16512 (patch) | |
tree | d786f7350b830cf1382549b30d3f44cc7becd3e1 /usr.sbin/bgpd/session.c | |
parent | 45d571d0ff10364e91baf98a590a3a961a5c27ff (diff) |
reserve upper half of the (internal) ID space for cloned neighbors, claudio ok
Diffstat (limited to 'usr.sbin/bgpd/session.c')
-rw-r--r-- | usr.sbin/bgpd/session.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/bgpd/session.c b/usr.sbin/bgpd/session.c index 657bc0ebf5b..ab40ffe6e28 100644 --- a/usr.sbin/bgpd/session.c +++ b/usr.sbin/bgpd/session.c @@ -1,4 +1,4 @@ -/* $OpenBSD: session.c,v 1.146 2004/04/25 08:06:00 henning Exp $ */ +/* $OpenBSD: session.c,v 1.147 2004/04/25 18:21:18 henning Exp $ */ /* * Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org> @@ -1912,7 +1912,7 @@ getpeerbyip(struct sockaddr *ip) if ((newpeer = malloc(sizeof(struct peer))) == NULL) fatal(NULL); memcpy(newpeer, loose, sizeof(struct peer)); - for (id = 1; id < UINT_MAX; id++) { + for (id = UINT_MAX; id > UINT_MAX / 2; id--) { for (p = peers; p != NULL && p->conf.id != id; p = p->next) ; /* nothing */ |