mirror of
https://github.com/hufrea/byedpi.git
synced 2024-12-22 14:25:44 +00:00
fix dereferencing type-punned pointer warning
This commit is contained in:
parent
ff4f811692
commit
64639d6661
3
proxy.c
3
proxy.c
@ -58,7 +58,8 @@ void map_fix(struct sockaddr_ina *addr, char f6)
|
|||||||
else if (!ipv6m->o64 && !ipv6m->o16 &&
|
else if (!ipv6m->o64 && !ipv6m->o16 &&
|
||||||
ipv6m->t16 == 0xffff && !f6) {
|
ipv6m->t16 == 0xffff && !f6) {
|
||||||
addr->sa.sa_family = AF_INET;
|
addr->sa.sa_family = AF_INET;
|
||||||
addr->in.sin_addr = *(struct in_addr *)(&ipv6m->o32);
|
const struct in_addr *sin_addr_ptr = (struct in_addr *) &ipv6m->o32;
|
||||||
|
addr->in.sin_addr = *sin_addr_ptr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user