Patch v4: Fix KEncodingProber crashiness
kumbayo84 at arcor.de
Sat Mar 21 17:06:28 GMT 2009
On Samstag 21 März 2009, Dan Meltzer wrote:
> On Sat, Mar 21, 2009 at 12:49 PM, Jeff Mitchell <mitchell at kde.org> wrote:
> > Christoph Feck wrote:
> >> Am Saturday 21 March 2009 16:03:20 schrieb Peter Oberndorfer:
> >>>> * Why not name it encoding() ?
> >>>> encodingNameByteArray reads very hackish...
> >> And why not just return a QString? Is there a reason the encoding needs to be
> >> specified in a specific encoding itself, so that it needs to be a byte array?
> > No idea. I was told on this list that the new function should return a
> > QByteArray -- so it does.
> > Anyways, I'm going to leave this to someone else to take care of. I am
> > mostly useless in improving the class as I know little about charsets,
> > but more importantly I didn't intend to get into long discussions of how
> > the class got to be where it is now and all the things wrong with it;
> > please discuss that with the author. I just wanted to fix the crash.
> > Whoever ends up taking care of this, please ensure it is ported back to
> > 4.2 branch so when Amarok 2.1 is released (which will probably be after
> > 4.2.2) people aren't crashing all over.
> I'm fairly sure that new api can't be added in a point release, which
> is going to make this difficult to backport...
Maybe we can return a strduped string like before.
and only add the QByteArray in 4.3
It leaks memory, but it also did that before.
I will think about it and try to come up with something.
> > Thanks,
> > Jeff
More information about the kde-core-devel