summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorSebastian Benoit <benno@cvs.openbsd.org>2015-11-17 09:15:22 +0000
committerSebastian Benoit <benno@cvs.openbsd.org>2015-11-17 09:15:22 +0000
commit124fc35584a05a792e3fed6ce6c51be8b399d2e2 (patch)
tree903035a4fa3594e61e43d1bf8dc36c78a36c777a /usr.sbin
parent73bc39ef3a570de150e1539b90e220a43ef06602 (diff)
in the SE, loosing the pipe to the main process can be handled with a
normal shutdown of sessions and exit. no need for fatal(). ok henning@ phessler@ florian@ happy deraadt@
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/bgpd/session.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/usr.sbin/bgpd/session.c b/usr.sbin/bgpd/session.c
index c5287d65dd0..56041d3943a 100644
--- a/usr.sbin/bgpd/session.c
+++ b/usr.sbin/bgpd/session.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: session.c,v 1.345 2015/10/25 18:49:01 claudio Exp $ */
+/* $OpenBSD: session.c,v 1.346 2015/11/17 09:15:21 benno Exp $ */
/*
* Copyright (c) 2003, 2004, 2005 Henning Brauer <henning@openbsd.org>
@@ -487,9 +487,11 @@ session_main(int debug, int verbose)
if (pauseaccept && getmonotime() > pauseaccept + 1)
pauseaccept = 0;
- if (handle_pollfd(&pfd[PFD_PIPE_MAIN], ibuf_main) == -1)
- fatalx("SE: Lost connection to parent");
- else
+ if (handle_pollfd(&pfd[PFD_PIPE_MAIN], ibuf_main) == -1) {
+ log_warnx("SE: Lost connection to parent");
+ session_quit = 1;
+ continue;
+ } else
session_dispatch_imsg(ibuf_main, PFD_PIPE_MAIN,
&listener_cnt);