Skip to content
Snippets Groups Projects
Commit 238752ed authored by rswindell's avatar rswindell
Browse files

Set file pointers to NULL in smtp_thread after closing, paranoia

(don't allow double-close).
parent 16ddb666
No related branches found
No related tags found
No related merge requests found
...@@ -1837,8 +1837,8 @@ static void smtp_thread(void* arg) ...@@ -1837,8 +1837,8 @@ static void smtp_thread(void* arg)
continue; continue;
} }
fclose(msgtxt); fclose(msgtxt), msgtxt=NULL;
fclose(rcptlst); fclose(rcptlst), rcptlst=NULL;
/* External Mail Processing here */ /* External Mail Processing here */
if(startup->proc_cfg_file[0] if(startup->proc_cfg_file[0]
...@@ -2821,7 +2821,7 @@ static void smtp_thread(void* arg) ...@@ -2821,7 +2821,7 @@ static void smtp_thread(void* arg)
continue; continue;
} }
if(msgtxt!=NULL) { if(msgtxt!=NULL) {
fclose(msgtxt); fclose(msgtxt), msgtxt=NULL;
if(!(startup->options&MAIL_OPT_DEBUG_RX_BODY)) if(!(startup->options&MAIL_OPT_DEBUG_RX_BODY))
unlink(msgtxt_fname); unlink(msgtxt_fname);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment