ImBuf: Fix OpenExr leaking memory when reading file with IB_test flag

This commit is contained in:
Sergey Sharybin 2015-07-23 09:10:11 +02:00
parent b6cf4f777d
commit 4be7fb7651
1 changed files with 2 additions and 4 deletions

View File

@ -2048,15 +2048,13 @@ struct ImBuf *imb_load_openexr(const unsigned char *mem, size_t size, int flags,
}
}
/* file is no longer needed */
delete membuf;
delete file;
}
}
if (flags & IB_alphamode_detect)
ibuf->flags |= IB_alphamode_premul;
}
delete file;
delete membuf;
return(ibuf);
}
catch (const std::exception& exc)