render_text fix
Maks Orlovich
maksim at cs.cornell.edu
Fri Jul 7 15:44:19 BST 2006
On Friday 07 July 2006 10:37, Pedro Suarez wrote:
> El Viernes, 7 de Julio de 2006 16:22, Maks Orlovich escribió:
> > On Friday 07 July 2006 08:08, Pedro Suarez wrote:
> > > I was trying testkhtml from trunk, and it crashed with the pages I was
> > > testing.
> > > The errors were due to accesses to incorrect positions in the m_lines
> > > vector.
> >
> > Good catch, please commit if you can... Sorry for missing this in the
> > review of the original patch, I thought it would be fine due to
> > reserve,but I guess it probably Q_ASSERTs?
>
> Rith, it Q_ASSERTs.
>
> And I was reading a bit the code, and I was thinking perhaps QList is a
> better choice than QVector, because that way you'd avoid reserves(), and
> because the list is always iterated completely... I don't know, it's just a
> thought
I don't think it would be, since QList tries to support prepends, too. This
just appends to the end, and hence a vector is perfect, and has very limited
overhead.
More information about the kfm-devel
mailing list