mindtct: Fix memory leak in error path in shape_from_contour()

libfprint/nbis/mindtct/shape.c:263:13: warning: Potential leak of memory pointed to by 'shape'
            fprintf(stderr,
            ^~~~~~~
This commit is contained in:
Bastien Nocera 2018-12-13 11:27:00 +01:00
parent a218437cf4
commit c3e996b96c

View file

@ -260,6 +260,7 @@ int shape_from_contour(SHAPE **oshape, const int *contour_x,
if(row->npts >= row->alloc){
/* This should never happen becuase we have allocated */
/* based on shape bounding limits. */
free(shape);
fprintf(stderr,
"ERROR : shape_from_contour : row overflow\n");
return(-260);