summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpyr <pyr@openbsd.org>2010-08-03 08:24:23 +0000
committerpyr <pyr@openbsd.org>2010-08-03 08:24:23 +0000
commit9c07f176d73defea99a4ff0cef571a3941ace0ae (patch)
tree3b5fa1ba08bf6b4141ae71dc2322c261606e2b2a
parentmatthew did not commit the diff he passed around for us to inspect... (diff)
downloadwireguard-openbsd-9c07f176d73defea99a4ff0cef571a3941ace0ae.tar.xz
wireguard-openbsd-9c07f176d73defea99a4ff0cef571a3941ace0ae.zip
Fix a leak in ypldap. Found (and correct diff) from
plalonde (at) overnet.qc.ca Prompted by deraadt@
-rw-r--r--usr.sbin/ypldap/yp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.sbin/ypldap/yp.c b/usr.sbin/ypldap/yp.c
index 2908d1cf804..20f68b475f2 100644
--- a/usr.sbin/ypldap/yp.c
+++ b/usr.sbin/ypldap/yp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: yp.c,v 1.5 2010/05/06 11:55:01 ajacoutot Exp $ */
+/* $OpenBSD: yp.c,v 1.6 2010/08/03 08:24:23 pyr Exp $ */
/*
* Copyright (c) 2008 Pierre-Yves Ritschard <pyr@openbsd.org>
*
@@ -91,6 +91,7 @@ yp_enable_events(void)
fatal(NULL);
event_set(&ye->ye_event, i, EV_READ, yp_fd_event, NULL);
event_add(&ye->ye_event, NULL);
+ TAILQ_INSERT_TAIL(&env->sc_yp->yd_events, ye, ye_entry);
}
}
}