themes.cpp fix scandir memleak

Origin commit data
------------------
Branch: ni/coolstream
Commit: ab396978a6
Author: Jacek Jendrzej <overx300@gmail.com>
Date: 2020-01-04 (Sat, 04 Jan 2020)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Jacek Jendrzej
2020-01-04 11:08:11 +01:00
committed by vanhofen
parent 442b9f5342
commit c939f59cd7

View File

@@ -552,7 +552,9 @@ void CThemes::move_userDir()
const char *target = ((std::string)THEMESDIR_VAR + "/" + file).c_str();
printf("[neutrino theme] moving %s to %s\n", dest, target);
rename(dest, target);
free(themelist[count]);
}
free(themelist);
}
printf("[neutrino theme] removing %s\n", USERDIR);
remove(USERDIR);