D9100: KUriFilter: simplify data structures, fix memory leak
David Faure
noreply at phabricator.kde.org
Sat Dec 2 14:26:19 UTC 2017
dfaure planned changes to this revision.
dfaure added inline comments.
INLINE COMMENTS
> kurifilter.cpp:665
> + QStringList res;
> + res.reserve(d->pluginList.size());
> + std::transform(d->pluginList.constBegin(), d->pluginList.constEnd(), res.begin(), [](const KUriFilterPlugin *plugin) { return plugin->objectName(); });
Interesting, to review my own commit from a month ago, after I forgot its details...
Dude, this code crashes, reserve+transform needs back_inserter, otherwise use resize!
REPOSITORY
R241 KIO
REVISION DETAIL
https://phabricator.kde.org/D9100
To: dfaure, apol, davidedmundson, arichardson, bshah
Cc: #frameworks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20171202/f3250eba/attachment.html>
More information about the Kde-frameworks-devel
mailing list