Page MenuHomeFreeBSD

D39012.diff
No OneTemporary

D39012.diff

diff --git a/libexec/tftpd/tests/functional.c b/libexec/tftpd/tests/functional.c
--- a/libexec/tftpd/tests/functional.c
+++ b/libexec/tftpd/tests/functional.c
@@ -319,7 +319,13 @@
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));

File Metadata

Mime Type
text/plain
Expires
Thu, Feb 6, 1:30 AM (20 h, 47 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16484405
Default Alt Text
D39012.diff (756 B)

Event Timeline