ref: 9445f08788765dbcc763cc0eab598216cca97667
parent: e49f7fc1f7435de94a632fea0dc7753b58570eb8
author: cinap_lenrek <[email protected]>
date: Sat Aug 11 12:19:32 EDT 2018
ip/ipconfig: call mklladdr() to get conf.hwa initialized for ipv6
--- a/sys/src/cmd/ip/ipconfig/ipconfig.h
+++ b/sys/src/cmd/ip/ipconfig/ipconfig.h
@@ -121,6 +121,7 @@
void adddefroute(uchar*, uchar*, uchar*, uchar*);
void removedefroute(int, uchar*, uchar*);
+void mklladdr(void);
long jitter(void);
void procsetname(char *fmt, ...);
void catch(void*, char*);
--- a/sys/src/cmd/ip/ipconfig/ipv6.c
+++ b/sys/src/cmd/ip/ipconfig/ipv6.c
@@ -1139,6 +1139,8 @@
{
static char routeon[] = "iprouting 1";
+ mklladdr();
+
if(conf.recvra > 0)
recvra6();
--- a/sys/src/cmd/ip/ipconfig/main.c
+++ b/sys/src/cmd/ip/ipconfig/main.c
@@ -392,8 +392,8 @@
}
doadd();
break;
- case Vaddpref6:
case Vra6:
+ case Vaddpref6:
doipv6(action);
break;
case Vremove:
@@ -413,7 +413,7 @@
}
/* create link local address */
-static void
+void
mklladdr(void)
{
if(isether() && myetheraddr(conf.hwa, conf.dev) == 0){