summaryrefslogtreecommitdiff
path: root/usr.sbin/ripd
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/ripd')
-rw-r--r--usr.sbin/ripd/imsg.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/ripd/imsg.c b/usr.sbin/ripd/imsg.c
index 83acd42c025..53ca8b4385a 100644
--- a/usr.sbin/ripd/imsg.c
+++ b/usr.sbin/ripd/imsg.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: imsg.c,v 1.8 2009/08/08 18:33:40 nicm Exp $ */
+/* $OpenBSD: imsg.c,v 1.9 2010/04/07 18:09:39 nicm Exp $ */
/*
* Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org>
@@ -79,7 +79,7 @@ imsg_read(struct imsgbuf *ibuf)
cmsg->cmsg_type == SCM_RIGHTS) {
fd = (*(int *)CMSG_DATA(cmsg));
if ((ifd = calloc(1, sizeof(struct imsg_fd))) == NULL) {
- /* XXX: this return can leak */
+ close(fd);
return (-1);
}
ifd->fd = fd;