* fhandler_socket.cc (fhandler_socket::ioctl): Return correct flags
for loopback interface when name is given on input instead of address.
This commit is contained in:
parent
0be1147408
commit
59ba222ca2
|
@ -1,3 +1,8 @@
|
||||||
|
2002-11-07 Gilles Courcoux <Gilles.Courcoux@col.bsf.alcatel.fr>
|
||||||
|
|
||||||
|
* fhandler_socket.cc (fhandler_socket::ioctl): Return correct flags
|
||||||
|
for loopback interface when name is given on input instead of address.
|
||||||
|
|
||||||
2002-11-07 Jason Tishler <jason@tishler.net>
|
2002-11-07 Jason Tishler <jason@tishler.net>
|
||||||
|
|
||||||
* cygwin.din: Export fseeko() and ftello().
|
* cygwin.din: Export fseeko() and ftello().
|
||||||
|
|
|
@ -1111,7 +1111,8 @@ fhandler_socket::ioctl (unsigned int cmd, void *p)
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
ifr->ifr_flags = IFF_NOTRAILERS | IFF_UP | IFF_RUNNING;
|
ifr->ifr_flags = IFF_NOTRAILERS | IFF_UP | IFF_RUNNING;
|
||||||
if (ntohl (((struct sockaddr_in *) &ifr->ifr_addr)->sin_addr.s_addr)
|
if (!strncmp(ifr->ifr_name, "lo", 2)
|
||||||
|
|| ntohl (((struct sockaddr_in *) &ifr->ifr_addr)->sin_addr.s_addr)
|
||||||
== INADDR_LOOPBACK)
|
== INADDR_LOOPBACK)
|
||||||
ifr->ifr_flags |= IFF_LOOPBACK;
|
ifr->ifr_flags |= IFF_LOOPBACK;
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue