reindex should cleanup its tempfiles

Signed-off-by: Janos SUTO <sj@acts.hu>
This commit is contained in:
Janos SUTO 2021-04-10 20:53:05 +02:00
parent e6607b0bf1
commit 10309b9c25

View File

@ -128,6 +128,9 @@ uint64 retrieve_email_by_metadata_id(struct session_data *sdata, struct data *da
rc = store_index_data(sdata, &state, data, stored_id, cfg); rc = store_index_data(sdata, &state, data, stored_id, cfg);
unlink(sdata->tmpframe);
remove_stripped_attachments(&state);
if(rc == OK) reindexed++; if(rc == OK) reindexed++;
else printf("failed to add to %s table: %s\n", SQL_SPHINX_TABLE, filename); else printf("failed to add to %s table: %s\n", SQL_SPHINX_TABLE, filename);