won't display the random, uninitialized value of peer6 for the system peer in the
no syspeer case on IPv6-capable hosts. Problem noted and solution provided by Matthias
Drochner, with a minor optimization by myself.
bk: 3f7dcd57GzKxGB2LrFIZ6hnp8uKPnQ
is = (struct info_sys *)prepare_pkt(srcadr, inter, inpkt,
v6sizeof(struct info_sys));
- is->peer = 0;
- is->peer_mode = 0;
if (sys_peer != 0) {
if (sys_peer->srcadr.ss_family == AF_INET) {
is->peer = GET_INADDR(sys_peer->srcadr);
is->v6_flag = 1;
}
is->peer_mode = sys_peer->hmode;
+ } else {
+ is->peer = 0;
+ if (client_v6_capable) {
+ is->v6_flag = 0;
+ }
+ is->peer_mode = 0;
}
is->leap = sys_leap;