From nobody Fri Mar 10 13:29:25 2023 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4PY6N54kSZz3xXNq; Fri, 10 Mar 2023 13:29:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4PY6N53xfFz3hMH; Fri, 10 Mar 2023 13:29:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1678454965; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Tujo1iAelk9aS7AU3aIUxIEkCOW6gL1cPBqdvoQSeIE=; b=LUyeTwXRepzxf46tXRjyZ5aF7lF8WVuBAzjUI1v21Hk211VO5zh1Tk/33jBvn48KoWrty6 472Yg731rP9vv9/hys0D44Xf7T+1UQh0s7W9/Tp1Ii3WTZfDHJt3Fl1+G+l/EglVIYFMJh o7eBMCfTWn9Uzdknbz7HZlkWEk+2V2RIFvsT/MpVIxeaxL4rSJhWnhieZYOXjuWbLNvqI9 r7GdrMv07pHDyagV/XgSyKgkZautpOlTSLuuHz3eAa2AK4svBnSkxcweqOPiEpoq4onaj1 bnU24GjfgC4oUT9vDFU2b/uW9f+kaULSPTq32XgKDDawwYXG9DpeA/PUd87fwQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1678454965; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Tujo1iAelk9aS7AU3aIUxIEkCOW6gL1cPBqdvoQSeIE=; b=UP2aAjmG6wrgiBj3RjEGZubRp/k6lFF9wewvYlDcP9gnJELMs69rgavVyPiqNLItuox+6q Y5jG+NUpxi1XPwKoakBA13NR2+tmbfYjFDXnE+MFXLAQxIJZLLG2uhkBmmaSa4eNyTgZns x/1jOiM4vuCEfQDbXMWFD6vDPCGAnLxFUjt1PeGojKHCv05iCxb6uinxdTSdEE/H+4+1Lw GaLSMVISF0ptQZAE2iInHbnOOdMMzAOxYrRX55A25KCQq/beROYmTFQ6if4JAmYRIBkua6 HGLnZFvKQkRzp5rQWslTWDtMRCqrM+r9AfzWcI9bmE4cyUSPTK2iutUs0d0wsQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1678454965; a=rsa-sha256; cv=none; b=pB/ee1l0V2OBl5b7yVcpuY6d3Ln0CYpRWUglJsX9re+nVqzi9b8uukc2rZn/pIk6ePzciX ORI7la8PySGTUUyDiiowv/DaDwgnMEBGLlOr8Lt5Mp9aToljoD56tEP30IPrEXSQ6Q2ejm l2f0GnO2OMMPr4tgi1xnRjQqN6UgsrApsB6U9w8UoT9acBiSi5COZSBEzh1D0rUh5/+Zd9 jH6WMsSBkAq+3oY+4wegNRWrbN0P+kSIuSVij34WxIkn6BFR06b+yUXEI3bYBmEe0lYocr p+NZuFMmDOWZkhdqGUXE8RPSvcyBGJJ7MxbtEbeG4ux7Gy0C0dGtHPc1n3SrSQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4PY6N532c2zqWR; Fri, 10 Mar 2023 13:29:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 32ADTPno090232; Fri, 10 Mar 2023 13:29:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 32ADTPAM090231; Fri, 10 Mar 2023 13:29:25 GMT (envelope-from git) Date: Fri, 10 Mar 2023 13:29:25 GMT Message-Id: <202303101329.32ADTPAM090231@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: =?utf-8?Q?Dag-Erling=20Sm=C3=B8rgrav?= Subject: git: 1955ad42b3b7 - main - tftpd: Gracefully skip tests if networking is not enabled. List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: des X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1955ad42b3b71a2083bd6d2aec0d9a10dd78eb21 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by des: URL: https://cgit.FreeBSD.org/src/commit/?id=1955ad42b3b71a2083bd6d2aec0d9a10dd78eb21 commit 1955ad42b3b71a2083bd6d2aec0d9a10dd78eb21 Author: Dag-Erling Smørgrav AuthorDate: 2023-03-10 13:25:00 +0000 Commit: Dag-Erling Smørgrav CommitDate: 2023-03-10 13:25:16 +0000 tftpd: Gracefully skip tests if networking is not enabled. Sponsored by: Klara, Inc. Reviewed by: asomers Differential Revision: https://reviews.freebsd.org/D39012 --- libexec/tftpd/tests/functional.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/libexec/tftpd/tests/functional.c b/libexec/tftpd/tests/functional.c index 8c35daf5cd65..36f22ea33294 100644 --- a/libexec/tftpd/tests/functional.c +++ b/libexec/tftpd/tests/functional.c @@ -319,7 +319,13 @@ setup(struct sockaddr_storage *to, uint16_t idx) ATF_REQUIRE_EQ(getcwd(pwd, sizeof(pwd)), pwd); /* Must bind(2) pre-fork so it happens before the client's send(2) */ - ATF_REQUIRE((server_s = socket(protocol, SOCK_DGRAM, 0)) > 0); + server_s = socket(protocol, SOCK_DGRAM, 0); + if (server_s < 0 && errno == EAFNOSUPPORT) { + atf_tc_skip("This test requires IPv%d support", + protocol == PF_INET ? 4 : 6); + } + ATF_REQUIRE_MSG(server_s >= 0, + "socket failed with error %s", strerror(errno)); ATF_REQUIRE_EQ_MSG(bind(server_s, server_addr, len), 0, "bind failed with error %s", strerror(errno));