fixed the close_peerlog() bug causing ipsec pluto --help to segfault

This commit is contained in:
Andreas Steffen
2008-08-01 10:12:33 +00:00
parent 39c0ae3780
commit 181abd3fdd
+1 -1
View File
@@ -95,7 +95,7 @@ void
close_peerlog(void) close_peerlog(void)
{ {
/* exit if the queue has not been initialized */ /* exit if the queue has not been initialized */
if (TAILQ_LAST(&perpeer_list, perpeer) == NULL) if (perpeer_list.tqh_last == NULL)
return; return;
/* end of queue is given by pointer to "HEAD" */ /* end of queue is given by pointer to "HEAD" */