Messages in this thread Patch in this message | | | Date | Thu, 10 Sep 1998 11:55:11 -0300 (EST) | From | Marcelo Tosatti <> | Subject | loopback hang |
| |
Augusto Cesar <bishop@sekure.org> pointed me a bug about loopback devices: ifconfig lo mtu 0 ping localhost (machine hang)
Fix attached.
- Marcelo --- dev.c.orig Thu Sep 10 11:51:08 1998 +++ dev.c Thu Sep 10 11:52:16 1998 @@ -19,6 +19,7 @@ * Adam Sulmicki <adam@cfar.umd.edu> * * Changes: + * Marcelo Tosatti <marcelo@conectiva.com.br> : dont accept mtu 0 or < * Alan Cox : device private ioctl copies fields back. * Alan Cox : Transmit queue code does relevant stunts to * keep the queue safe. @@ -1470,7 +1471,7 @@ * MTU must be positive. */ - if (ifr->ifr_mtu<0) + if (ifr->ifr_mtu<=0) return -EINVAL; if (dev->change_mtu) | |