2010-07-16 Dario Rodriguez <dario.rodriguez@artica.es>

* misc/pandora_file.cc: fixed error that caused double free.



git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@3019 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
darode 2010-07-16 12:42:38 +00:00
parent afb6e012a9
commit 24f85e81ca
2 changed files with 4 additions and 4 deletions

View File

@ -1,3 +1,7 @@
2010-07-16 Dario Rodriguez <dario.rodriguez@artica.es>
* misc/pandora_file.cc: fixed error that caused double free.
2010-07-16 Dario Rodriguez <dario.rodriguez@artica.es>
* misc/pandora_file.cc: fixed unclosed directory with function closedir

View File

@ -165,15 +165,11 @@ Pandora_File::removeDir (const string filepath) {
if(errno == ENOTDIR) {
if (remove (filepath.c_str ()) == -1) {
/*Close dir oppened*/
closedir(dir);
return DELETE_ERROR;
}
return 0;
} else {
/*Close dir oppened*/
closedir(dir);
return DELETE_ERROR;
}
}