Re: [patch] Verify that ifaddr_byindex(foo) != NULL

2004-05-04 Thread Luigi Rizzo
On Wed, May 05, 2004 at 07:02:33AM +0100, Colin Percival wrote: ... > >On Tue, May 04, 2004 at 01:42:20PM +0100, Colin Percival wrote: > >> if we're going to check that > >> 0 < ifp->if_index <= if_index, it seems that we should also be > >> checking that ifp->if_index corresponds to an interface w

Re: [patch] Verify that ifaddr_byindex(foo) != NULL

2004-05-04 Thread Colin Percival
At 14:35 04/05/2004, Luigi Rizzo wrote: >On Tue, May 04, 2004 at 01:42:20PM +0100, Colin Percival wrote: >> if we're going to check that >> 0 < ifp->if_index <= if_index, it seems that we should also be >> checking that ifp->if_index corresponds to an interface which >> still exists (rather than a

Re: [patch] Verify that ifaddr_byindex(foo) != NULL

2004-05-04 Thread Luigi Rizzo
On Tue, May 04, 2004 at 01:42:20PM +0100, Colin Percival wrote: > Could someone confirm for me that this looks sensible? I don't > know anything about this code, but if we're going to check that > 0 < ifp->if_index <= if_index, it seems that we should also be > checking that ifp->if_index corres

[patch] Verify that ifaddr_byindex(foo) != NULL

2004-05-04 Thread Colin Percival
Could someone confirm for me that this looks sensible? I don't know anything about this code, but if we're going to check that 0 < ifp->if_index <= if_index, it seems that we should also be checking that ifp->if_index corresponds to an interface which still exists (rather than a gap left behind