From: bluhm Date: Thu, 6 Jul 2017 13:20:54 +0000 (+0000) Subject: Initialize the return value and do not use garbage as exit status. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=b12e34d890b3bf15524cef407ce49bc0f666e99a;p=openbsd Initialize the return value and do not use garbage as exit status. Then the test passes. --- diff --git a/regress/sys/netinet/in_pcbbind/runtest.c b/regress/sys/netinet/in_pcbbind/runtest.c index 5baba0cb5de..e26d2832dce 100644 --- a/regress/sys/netinet/in_pcbbind/runtest.c +++ b/regress/sys/netinet/in_pcbbind/runtest.c @@ -1,4 +1,4 @@ -/* $OpenBSD: runtest.c,v 1.4 2016/09/05 10:15:24 vgross Exp $ */ +/* $OpenBSD: runtest.c,v 1.5 2017/07/06 13:20:54 bluhm Exp $ */ /* * Copyright (c) 2015 Vincent Gross * @@ -120,6 +120,7 @@ unicast_testsuite(struct addrinfo *local, struct addrinfo *any) int test_rc, rc, *s; int sockets[4]; + test_rc = 0; rc = 0; s = sockets; rc |= runtest(s++, local, 0, 0, NULL, 0); rc |= runtest(s++, any, 0, 0, NULL, EADDRINUSE); @@ -186,6 +187,7 @@ mcast_reuse_testsuite(struct addrinfo *local, void *mr) int sockets[6]; int testnum = 1; + test_rc = 0; rc = 0; s = sockets; rc |= runtest(s++, local, 0, 0, mr, 0); rc |= runtest(s++, local, 1, 0, mr, EADDRINUSE); @@ -272,6 +274,7 @@ mcast6_testsuite(struct addrinfo *local, struct ipv6_mreq *local_mreq, int sockets[4]; int testnum = 1; + test_rc = 0; rc = 0; s = sockets; rc |= runtest(s++, local, 0, 0, local_mreq, 0); rc |= runtest(s++, any, 0, 0, any_mreq, EADDRINUSE);