tools: imx8mimage: Fix potential memory leak
Dynamic memory, referenced by 'line', is allocated at imx8mimage.c:187 by calling function 'getline' and lost at imx8mimage.c:210. Signed-off-by: Maks Mishin <maks.mishinFZ@gmail.com>
This commit is contained in:

committed by
Fabio Estevam

parent
410ef0bb34
commit
959f331659
@@ -206,6 +206,7 @@ static uint32_t parse_cfg_file(char *name)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
free(line);
|
||||||
fclose(fd);
|
fclose(fd);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user