update: clear root after error
When the root directory fails to update, its contents are invalid. Clear it then.
This commit is contained in:
parent
2bb7bcc7b6
commit
2ae94fec6d
@ -408,6 +408,7 @@ static enum update_return updatePath(const char *utf8path)
|
||||
/* we don't want to delete the root directory */
|
||||
else if (directory == db_get_root()) {
|
||||
free(path);
|
||||
clear_directory(directory);
|
||||
return UPDATE_RETURN_NOUPDATE;
|
||||
}
|
||||
/* if updateDirectory fails, means we should delete it */
|
||||
|
Loading…
Reference in New Issue
Block a user