From d5b111ec99f737a7db7a6b9a329e19cd9f1a80a9 Mon Sep 17 00:00:00 2001 From: yuyi Date: Mon, 3 Jan 2022 14:45:26 +0800 Subject: [PATCH] net: fix typo in new_ip() (#13017) --- vlib/net/address.v | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vlib/net/address.v b/vlib/net/address.v index 868f649a8a..4c41303a2d 100644 --- a/vlib/net/address.v +++ b/vlib/net/address.v @@ -24,7 +24,7 @@ fn new_ip6(port u16, addr [16]byte) Addr { } } - copy(a.addr.Ip6.addr[0..], addr[0..]) + copy(a.addr.Ip6.addr[..], addr[..]) return a } @@ -39,7 +39,7 @@ fn new_ip(port u16, addr [4]byte) Addr { } } - copy(a.addr.Ip6.addr[0..], addr[0..]) + copy(a.addr.Ip.addr[..], addr[..]) return a }