Hi On 8/7/06, Christian Ehrlicher <[EMAIL PROTECTED]> wrote: > > > #ifdef WIN32 > > > info.name = static_cast<const char*>(f.lower()); > > > #else > > > info.name = strdup(QFile::encodeName(f)); > > > #endif > > > > > > > > > Why was this small memleak only fixed for win32? And why isn't the > > filename encoded on win32? > > > > 1. http://doc.trolltech.com/3.3/qfile.html#encodeName : > > On Windows NT/2000, Unicode file names are supported directly in the > > file system and this function should be avoided. > > > This has imho nothing to do with the problem because we don't use native file > functions here. Only Qt ones. And if you don't encode a name but later decode > them for e.g. QFile() it is wrong afterwards...
what do you mean? the above sentence about avoiding the QFile::encodeName() is quoted from Qt's documentation, so it is Trolltech who recommends against using it. I would follow their recommendations. > > 2. Yes, strdup should be removed in both calls, because > > pluginInfo::name is std::string now. > I'm using QString now... I'm ok with it > Christian > -- -- BR. Alexander 'zowers' Petrov. jabber:[EMAIL PROTECTED] icq:69694782 http://zowers.googlepages.com/ mailto:[EMAIL PROTECTED] _______________________________________________ sim-im-main mailing list [email protected] https://mailman.dg.net.ua/listinfo/sim-im-main
