fix a memory leak
This commit is contained in:
parent
b9d963dfa2
commit
cd1f278d45
@ -167,6 +167,10 @@ if (NULL == fimg->R) {
|
|||||||
|
|
||||||
|
|
||||||
free(fimg->R);
|
free(fimg->R);
|
||||||
|
if (FIMG_TYPE_RGB==fimg->type) {
|
||||||
|
free(fimg->G);
|
||||||
|
free(fimg->B);
|
||||||
|
}
|
||||||
memset(fimg, 0, sizeof(FloatImg));
|
memset(fimg, 0, sizeof(FloatImg));
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user