gui: IPCPreviewWorker(): Don't allocate mapfunctor on heap
Este cometimento está contido em:
ascendente
f8fe21d50b
cometimento
c867652b6f
@ -10,13 +10,11 @@ IPCPreviewWorker::IPCPreviewWorker()
|
||||
|
||||
void IPCPreviewWorker::start(RenderConfig config, const QVector<RenderTarget> &targets, QLocalSocket *peer)
|
||||
{
|
||||
|
||||
stop();
|
||||
/* TODO: memleak */
|
||||
auto mapFunctor = new PreviewGeneratorMapFunctor();
|
||||
mapFunctor->setRenderConfig(config);
|
||||
auto mapFunctor = PreviewGeneratorMapFunctor();
|
||||
mapFunctor.setRenderConfig(config);
|
||||
|
||||
previewWorkerWatcher.setFuture(QtConcurrent::mapped(targets, *mapFunctor));
|
||||
previewWorkerWatcher.setFuture(QtConcurrent::mapped(targets, mapFunctor));
|
||||
}
|
||||
|
||||
void IPCPreviewWorker::stop()
|
||||
|
Carregando…
Criar uma nova questão referindo esta
Bloquear um utilizador