Em Qua, 2006-12-06 às 17:12 +0100, Andreas Barth escreveu:
> * Goedson Teixeira Paixao ([EMAIL PROTECTED]) [061206 17:07]:
> > diff -ru apt-0.6.46.3/apt-pkg/deb/debindexfile.cc 
> > apt-0.6.46.3.new/apt-pkg/deb/debindexfile.cc
> > --- apt-0.6.46.3/apt-pkg/deb/debindexfile.cc        2006-03-29 
> > 22:27:33.000000000 -0300
> > +++ apt-0.6.46.3.new/apt-pkg/deb/debindexfile.cc    2006-12-06 
> > 13:19:36.000000000 -0200
> > @@ -305,7 +305,7 @@
> >     pkgCache::PkgFileIterator File = Cache.FileBegin();
> >     for (; File.end() == false; File++)
> >     {
> > -      if (FileName != File.FileName())
> > +       if (File.FileName() != NULL && FileName != File.FileName())
> >      continue;
> >        
> >        struct stat St;
> 
> I assume that only this fix is responsible for not segfaulting anymore,
> and rest is for fixing the FTBFS (that I cannot reproduce, btw).

I've just reviewed the patch above and, although it did avoid the
segmentation fault, I believe the condition should be:

 if (File.FileName() == NULL || FileName != File.FileName())

I've just tested APT this way and it is all fine.


-- 
Goedson Teixeira Paixao          http://mundolivre.wordpress.com/
Debian Project                   http://www.debian.org/
Jabber ID: [EMAIL PROTECTED]    http://www.jabber.org/

Attachment: signature.asc
Description: Esta é uma parte de mensagem assinada digitalmente

Reply via email to