Fix two memleaks found by coverity.
This commit is contained in:
parent
ae475e3554
commit
64a6a86d57
|
@ -585,6 +585,9 @@ static void import_startjob(void *user_data, short *stop, short *do_update, floa
|
|||
IArchive *archive = open_archive(data->filename);
|
||||
|
||||
if (!archive || !archive->valid()) {
|
||||
if (archive) {
|
||||
delete archive;
|
||||
}
|
||||
data->error_code = ABC_ARCHIVE_FAIL;
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -49,6 +49,7 @@ void TransformWriter::add_node_transform(COLLADASW::Node& node, float mat[4][4],
|
|||
double dmat[4][4];
|
||||
UnitConverter *converter = new UnitConverter();
|
||||
converter->mat4_to_dae_double(dmat, local);
|
||||
delete converter;
|
||||
|
||||
TransformBase::decompose(local, loc, rot, NULL, scale);
|
||||
|
||||
|
|
Loading…
Reference in New Issue