create report directory before writing reports.txt

This commit is contained in:
Enno Rehling 2014-03-22 23:14:36 +01:00
parent b399356971
commit 0d8a196491
1 changed files with 1 additions and 0 deletions

View File

@ -1754,6 +1754,7 @@ int reports(void)
report_donations(); report_donations();
remove_empty_units(); remove_empty_units();
_mkdir(reportpath());
sprintf(path, "%s/reports.txt", reportpath()); sprintf(path, "%s/reports.txt", reportpath());
mailit = fopen(path, "w"); mailit = fopen(path, "w");
if (mailit == NULL) { if (mailit == NULL) {