loadFile: fix double free

This commit is contained in:
Philippe Teuwen 2019-03-08 19:49:12 +01:00
commit abddff513e
3 changed files with 6 additions and 12 deletions

View file

@ -248,6 +248,7 @@ int CmdFlashMemLoad(const char *Cmd){
res = loadFile(filename, "bin", data, &datalen);
//int res = loadFileEML( filename, "eml", data, &datalen);
if ( res ) {
free(data);
return 1;
}
@ -607,4 +608,4 @@ int CmdHelp(const char *Cmd) {
return 0;
}
#endif
#endif