aboutsummaryrefslogtreecommitdiff
path: root/lib/std/net
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2020-06-02 15:28:46 -0400
committerAndrew Kelley <andrew@ziglang.org>2020-06-02 15:28:46 -0400
commit7fd937fef4547a98d7c33ea67eca76e6336f9152 (patch)
tree9122d4a2eab8b9deef81e089cecee0e7699a08fa /lib/std/net
parent0d091dc92374a49c41d406b5bf9a4b508a3d450c (diff)
downloadzig-7fd937fef4547a98d7c33ea67eca76e6336f9152.tar.gz
zig-7fd937fef4547a98d7c33ea67eca76e6336f9152.zip
cleanups
* improve docs * add TODO comments for things that don't have open issues * remove redundant namespacing of struct fields * guard against ioctl returning EINTR * remove the general std.os.ioctl function in favor of the specific ioctl_SIOCGIFINDEX function. This allows us to have a more precise error set, and more type-safe API.
Diffstat (limited to 'lib/std/net')
-rw-r--r--lib/std/net/test.zig4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/std/net/test.zig b/lib/std/net/test.zig
index cec9185eae..5327e88ffc 100644
--- a/lib/std/net/test.zig
+++ b/lib/std/net/test.zig
@@ -48,6 +48,7 @@ test "parse and render IPv6 addresses" {
testing.expectError(error.InvalidEnd, net.Address.parseIp6("FF01:0:0:0:0:0:0:FB:", 0));
testing.expectError(error.Incomplete, net.Address.parseIp6("FF01:", 0));
testing.expectError(error.InvalidIpv4Mapping, net.Address.parseIp6("::123.123.123.123", 0));
+ // TODO Make this test pass on other operating systems.
if (std.builtin.os.tag == .linux) {
testing.expectError(error.Incomplete, net.Address.resolveIp6("ff01::fb%", 0));
testing.expectError(error.Overflow, net.Address.resolveIp6("ff01::fb%wlp3s0s0s0s0s0s0s0s0", 0));
@@ -56,8 +57,9 @@ test "parse and render IPv6 addresses" {
}
test "invalid but parseable IPv6 scope ids" {
- // Currently, resolveIp6 with alphanumerical scope IDs only works on Linux.
if (std.builtin.os.tag != .linux) {
+ // Currently, resolveIp6 with alphanumerical scope IDs only works on Linux.
+ // TODO Make this test pass on other operating systems.
return error.SkipZigTest;
}