[poppler] poppler/poppler: PDFDoc.cc,1.2,1.3

Albert Astals Cid aacid at kde.org
Mon Aug 8 02:32:27 EST 2005


Here's my patch that does what i said.

Agree to commit?

Albert

A Diumenge 07 Agost 2005 15:01, Albert Astals Cid va escriure:
> Wouldn't be better starting to check from the end of eof and not for the
> start as %%EOF is supposed to be at the end of it?
>
> Albert
>
> A Diumenge 07 Agost 2005 07:51, Kristian Høgsberg va escriure:
> > Brad Hards wrote:
> > > On Sun, 7 Aug 2005 08:59 am, Brad Hards wrote:
> > >>On Sat, 6 Aug 2005 21:47 pm, Albert Astals Cid wrote:
> > >>>Update of /cvs/poppler/poppler/poppler
> > >>>In directory gabe:/tmp/cvs-serv16924/poppler
> > >>>
> > >>>Modified Files:
> > >>>	PDFDoc.cc
> > >>>Log Message:
> > >>>Increase EOF searching up to last 1024 characters
> > >>
> > >>Hmm, that broke the qt4 unittests:
> > >
> > > Actually, looks like most of the problem is one file - orientation.pdf.
> > > See
> > > http://cvs.freedesktop.org/poppler/test/unittestcases/orientation.pdf?r
> > >ev =1.1&view=log
> > >
> > > I think that the problem is that strstr() stops at the first 0x00, and
> > > that file (plus a few others I found, mostly linearized and/or
> > > encrypted) do have embedded 0x00's. I hacked it (see below) to avoid
> > > putting those into eof[], and it now Works For Me(tm).
> > >
> > > Should I commit this, ugly as it is?
> >
> > Hmm, I'd rather see something like
> >
> >     for (i = 0; i < len - 5; i++)
> >       if (strncmp (eof + i, "%%EOF", 5) == 0)
> >         break;
> >
> > etc.
> >
> > Kristian
> >
> > _______________________________________________
> > poppler mailing list
> > poppler at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/poppler
>
> ______________________________________________
> Renovamos el Correo Yahoo!
> Nuevos servicios, ms seguridad
> http://correo.yahoo.es
> _______________________________________________
> poppler mailing list
> poppler at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/poppler
-------------- next part --------------
A non-text attachment was scrubbed...
Name: eof2.patch
Type: text/x-diff
Size: 654 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/poppler/attachments/20050807/04cd75d3/eof2.bin


More information about the poppler mailing list