bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] About the bug that makes pfinet crash


From: Samuel Thibault
Subject: Re: [PATCH] About the bug that makes pfinet crash
Date: Mon, 24 Nov 2008 19:51:21 +0100
User-agent: Mutt/1.5.12-2006-07-14

Thomas Schwinge, le Mon 24 Nov 2008 11:43:58 +0100, a écrit :
> > > - if (count == 0 || count > PAGE_SIZE)
> > > + if (count < ifp->if_header_size ||
> > > +     count > ifp->if_header_size + ifp->if_mtu)
> > >           return D_INVALID_SIZE;
> > >  
> > >           assert(copy->type == VM_MAP_COPY_PAGE_LIST);
> > 
> > Mmm, the < should be fine, but I'd rather see the > still use PAGE_SIZE,
> > or perhaps replace these PAGE_SIZE occurrences with a macro defed to
> > PAGE_SIZE.
> 
> Or what about installing my change as given above, but also adding an
> ``assert (ifp->if_header_size + ifp->if_mtu <= PAGE_SIZE)''?

Why not indeed.

Samuel




reply via email to

[Prev in Thread] Current Thread [Next in Thread]