diff options
author | Claudio Jeker <claudio@cvs.openbsd.org> | 2004-02-19 13:54:59 +0000 |
---|---|---|
committer | Claudio Jeker <claudio@cvs.openbsd.org> | 2004-02-19 13:54:59 +0000 |
commit | ab07350c16c79d16babb36da629198c73a1497b5 (patch) | |
tree | 41595ba2bafa7881347f58e3f922b82c7e80a280 /usr.sbin/bgpd/rde_attr.c | |
parent | 66c12e8fef994277c60a99cb9e108d32aea1310b (diff) |
Make the code more portable. Add some missing header files and make the use
of the queue(3) makros more portable. OK henning@ some time ago.
Diffstat (limited to 'usr.sbin/bgpd/rde_attr.c')
-rw-r--r-- | usr.sbin/bgpd/rde_attr.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.sbin/bgpd/rde_attr.c b/usr.sbin/bgpd/rde_attr.c index b21349b2732..e4185f45923 100644 --- a/usr.sbin/bgpd/rde_attr.c +++ b/usr.sbin/bgpd/rde_attr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rde_attr.c,v 1.10 2004/02/19 10:55:41 claudio Exp $ */ +/* $OpenBSD: rde_attr.c,v 1.11 2004/02/19 13:54:58 claudio Exp $ */ /* * Copyright (c) 2004 Claudio Jeker <claudio@openbsd.org> @@ -339,7 +339,7 @@ attr_compare(struct attr_flags *a, struct attr_flags *b) return (-1); for (oa = TAILQ_FIRST(&a->others), ob = TAILQ_FIRST(&b->others); - oa != TAILQ_END(&a->others) && ob != TAILQ_END(&a->others); + oa != NULL && ob != NULL; oa = TAILQ_NEXT(oa, attr_l), ob = TAILQ_NEXT(ob, attr_l)) { if (oa->type > ob->type) return (1); @@ -355,9 +355,9 @@ attr_compare(struct attr_flags *a, struct attr_flags *b) if (r < 0) return (-1); } - if (oa != TAILQ_END(&a->others)) + if (oa != NULL) return (1); - if (ob != TAILQ_END(&a->others)) + if (ob != NULL) return (-1); return (0); } |