summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Bluhm <bluhm@cvs.openbsd.org>2010-06-12 10:12:42 +0000
committerAlexander Bluhm <bluhm@cvs.openbsd.org>2010-06-12 10:12:42 +0000
commit70e026f83d4a252687bc283082d621be3d75c37b (patch)
tree9b08946c5c8ff4d80a625f9d8120f75c991af12a
parentb05f1f25a291e3eb44d93e53e45d8c33ce771654 (diff)
Add a missing ntohs() around hdr.type. This fixes a segfault as
the area of an ASE LSA is NULL. ok claudio@
-rw-r--r--usr.sbin/ospf6d/rde_lsdb.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/ospf6d/rde_lsdb.c b/usr.sbin/ospf6d/rde_lsdb.c
index c3a7692aa91..1c9601a7e7e 100644
--- a/usr.sbin/ospf6d/rde_lsdb.c
+++ b/usr.sbin/ospf6d/rde_lsdb.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rde_lsdb.c,v 1.31 2010/06/09 17:36:36 claudio Exp $ */
+/* $OpenBSD: rde_lsdb.c,v 1.32 2010/06/12 10:12:41 bluhm Exp $ */
/*
* Copyright (c) 2004, 2005 Claudio Jeker <claudio@openbsd.org>
@@ -787,7 +787,7 @@ lsa_timeout(int fd, short event, void *bula)
v->deleted = 0;
/* schedule recalculation of the RIB */
- if (v->lsa->hdr.type != LSA_TYPE_EXTERNAL)
+ if (ntohs(v->lsa->hdr.type) != LSA_TYPE_EXTERNAL)
v->area->dirty = 1;
start_spf_timer();