Commit 0f1c464a authored by Boudewijn Rempt's avatar Boudewijn Rempt

Fix memory leak

CID:248404
parent 598d34e2
......@@ -296,6 +296,7 @@ KisImportExportErrorCode KisXCFImport::convert(KisDocument *document, QIODevice
want.r = want.l + TILE_WIDTH;
Tile* tile = getMaskOrLayerTile(&xcflayer.dim, &xcflayer.mask, want);
if (tile == XCF_PTR_EMPTY) {
delete tile;
return ImportExportCodes::FileFormatIncorrect;
}
KisHLineIteratorSP it = mask->paintDevice()->createHLineIteratorNG(x, y, TILE_WIDTH);
......@@ -307,7 +308,7 @@ KisImportExportErrorCode KisXCFImport::convert(KisDocument *document, QIODevice
} while (it->nextPixel());
it->nextRow();
}
delete tile;
}
}
mask->paintDevice()->setX(left);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment