From: claudio Date: Thu, 4 Mar 2021 14:04:47 +0000 (+0000) Subject: Replace NOTREACHED with actuall errx() calls. I managed to return from X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=fee61e1e3d9efe78bde01f0eddf3f1a4db9e3230;p=openbsd Replace NOTREACHED with actuall errx() calls. I managed to return from the proc_xyz() function at least in two occastions and it is not that trivial to realize what goes wrong. --- diff --git a/usr.sbin/rpki-client/main.c b/usr.sbin/rpki-client/main.c index cc31407ccf3..9a09d0be002 100644 --- a/usr.sbin/rpki-client/main.c +++ b/usr.sbin/rpki-client/main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: main.c,v 1.109 2021/03/04 13:01:41 claudio Exp $ */ +/* $OpenBSD: main.c,v 1.110 2021/03/04 14:04:47 claudio Exp $ */ /* * Copyright (c) 2019 Kristaps Dzonsons * @@ -1001,7 +1001,7 @@ main(int argc, char *argv[]) if (pledge("stdio rpath", NULL) == -1) err(1, "pledge"); proc_parser(fd[0]); - /* NOTREACHED */ + errx(1, "parser process returned"); } close(fd[0]); @@ -1028,7 +1028,7 @@ main(int argc, char *argv[]) err(1, "pledge"); proc_rsync(rsync_prog, bind_addr, fd[0]); - /* NOTREACHED */ + errx(1, "rsync process returned"); } close(fd[0]); @@ -1061,7 +1061,7 @@ main(int argc, char *argv[]) err(1, "pledge"); proc_http(bind_addr, fd[0]); - /* NOTREACHED */ + errx(1, "http process returned"); } close(fd[0]);