summaryrefslogtreecommitdiff
path: root/usr.sbin/bgpd/session.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/bgpd/session.c')
-rw-r--r--usr.sbin/bgpd/session.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/usr.sbin/bgpd/session.c b/usr.sbin/bgpd/session.c
index 334b1028a49..49a10e1c88d 100644
--- a/usr.sbin/bgpd/session.c
+++ b/usr.sbin/bgpd/session.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: session.c,v 1.488 2024/11/21 13:17:01 claudio Exp $ */
+/* $OpenBSD: session.c,v 1.489 2024/11/21 13:17:57 claudio Exp $ */
/*
* Copyright (c) 2003, 2004, 2005 Henning Brauer <henning@openbsd.org>
@@ -475,7 +475,7 @@ session_main(int debug, int verbose)
if (handle_pollfd(&pfd[PFD_PIPE_ROUTE], ibuf_rde) == -1) {
log_warnx("SE: Lost connection to RDE");
- msgbuf_clear(&ibuf_rde->w);
+ imsgbuf_clear(ibuf_rde);
free(ibuf_rde);
ibuf_rde = NULL;
} else
@@ -485,7 +485,7 @@ session_main(int debug, int verbose)
if (handle_pollfd(&pfd[PFD_PIPE_ROUTE_CTL], ibuf_rde_ctl) ==
-1) {
log_warnx("SE: Lost connection to RDE control");
- msgbuf_clear(&ibuf_rde_ctl->w);
+ imsgbuf_clear(ibuf_rde_ctl);
free(ibuf_rde_ctl);
ibuf_rde_ctl = NULL;
} else
@@ -540,17 +540,17 @@ session_main(int debug, int verbose)
/* close pipes */
if (ibuf_rde) {
imsgbuf_write(ibuf_rde);
- msgbuf_clear(&ibuf_rde->w);
+ imsgbuf_clear(ibuf_rde);
close(ibuf_rde->fd);
free(ibuf_rde);
}
if (ibuf_rde_ctl) {
- msgbuf_clear(&ibuf_rde_ctl->w);
+ imsgbuf_clear(ibuf_rde_ctl);
close(ibuf_rde_ctl->fd);
free(ibuf_rde_ctl);
}
imsgbuf_write(ibuf_main);
- msgbuf_clear(&ibuf_main->w);
+ imsgbuf_clear(ibuf_main);
close(ibuf_main->fd);
free(ibuf_main);
@@ -2962,7 +2962,7 @@ session_dispatch_imsg(struct imsgbuf *imsgbuf, int idx, u_int *listener_cnt)
if (ibuf_rde) {
log_warnx("Unexpected imsg connection "
"to RDE received");
- msgbuf_clear(&ibuf_rde->w);
+ imsgbuf_clear(ibuf_rde);
free(ibuf_rde);
}
ibuf_rde = i;
@@ -2970,7 +2970,7 @@ session_dispatch_imsg(struct imsgbuf *imsgbuf, int idx, u_int *listener_cnt)
if (ibuf_rde_ctl) {
log_warnx("Unexpected imsg ctl "
"connection to RDE received");
- msgbuf_clear(&ibuf_rde_ctl->w);
+ imsgbuf_clear(ibuf_rde_ctl);
free(ibuf_rde_ctl);
}
ibuf_rde_ctl = i;