Von: "Alexander Petrov" <[EMAIL PROTECTED]> > 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...
> 2. Yes, strdup should be removed in both calls, because > pluginInfo::name is std::string now. I'm using QString now... Christian -- Echte DSL-Flatrate dauerhaft für 0,- Euro*. Nur noch kurze Zeit! "Feel free" mit GMX DSL: http://www.gmx.net/de/go/dsl -- Echte DSL-Flatrate dauerhaft für 0,- Euro*. Nur noch kurze Zeit! "Feel free" mit GMX DSL: http://www.gmx.net/de/go/dsl _______________________________________________ sim-im-main mailing list [email protected] https://mailman.dg.net.ua/listinfo/sim-im-main
