summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPierre-Yves Ritschard <pyr@cvs.openbsd.org>2007-07-16 21:14:59 +0000
committerPierre-Yves Ritschard <pyr@cvs.openbsd.org>2007-07-16 21:14:59 +0000
commitf987d306241a3858a27481395e6cd2077d984cfb (patch)
tree5350d1d93a7e3d8f6d2d4907d83900522a2ad7e2
parent9abda7c2a26a160604b4f0c20ce86e273fcbdc98 (diff)
use fatal and not err, the message would get lost.
found by Kevin Steves <stevesk (at) pobox dot com>
-rw-r--r--usr.sbin/hoststated/check_icmp.c5
-rw-r--r--usr.sbin/relayd/check_icmp.c5
2 files changed, 4 insertions, 6 deletions
diff --git a/usr.sbin/hoststated/check_icmp.c b/usr.sbin/hoststated/check_icmp.c
index 09a3555ed15..558fc6907c2 100644
--- a/usr.sbin/hoststated/check_icmp.c
+++ b/usr.sbin/hoststated/check_icmp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: check_icmp.c,v 1.16 2007/05/31 03:24:05 pyr Exp $ */
+/* $OpenBSD: check_icmp.c,v 1.17 2007/07/16 21:14:58 pyr Exp $ */
/*
* Copyright (c) 2006 Pierre-Yves Ritschard <pyr@spootnik.org>
@@ -33,7 +33,6 @@
#include <unistd.h>
#include <string.h>
#include <stdlib.h>
-#include <err.h>
#include <openssl/ssl.h>
@@ -56,7 +55,7 @@ icmp_setup(struct hoststated *env, struct ctl_icmp_event *cie, int af)
if (af == AF_INET6)
proto = IPPROTO_ICMPV6;
if ((cie->s = socket(af, SOCK_RAW, proto)) < 0)
- err(1, "icmp_init: socket");
+ fatal("icmp_init: socket");
session_socket_blockmode(cie->s, BM_NONBLOCK);
cie->env = env;
cie->af = af;
diff --git a/usr.sbin/relayd/check_icmp.c b/usr.sbin/relayd/check_icmp.c
index 09a3555ed15..558fc6907c2 100644
--- a/usr.sbin/relayd/check_icmp.c
+++ b/usr.sbin/relayd/check_icmp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: check_icmp.c,v 1.16 2007/05/31 03:24:05 pyr Exp $ */
+/* $OpenBSD: check_icmp.c,v 1.17 2007/07/16 21:14:58 pyr Exp $ */
/*
* Copyright (c) 2006 Pierre-Yves Ritschard <pyr@spootnik.org>
@@ -33,7 +33,6 @@
#include <unistd.h>
#include <string.h>
#include <stdlib.h>
-#include <err.h>
#include <openssl/ssl.h>
@@ -56,7 +55,7 @@ icmp_setup(struct hoststated *env, struct ctl_icmp_event *cie, int af)
if (af == AF_INET6)
proto = IPPROTO_ICMPV6;
if ((cie->s = socket(af, SOCK_RAW, proto)) < 0)
- err(1, "icmp_init: socket");
+ fatal("icmp_init: socket");
session_socket_blockmode(cie->s, BM_NONBLOCK);
cie->env = env;
cie->af = af;