/* Copyright (c) Tom Kistner <tom@duncanthrax.net> 2003-2015
* License: GPL
- * Copyright (c) The Exim Maintainers 2016
+ * Copyright (c) The Exim Maintainers 2016 - 2018
*/
/* Code for matching regular expressions against headers and body.
if (!mime_stream) /* We are in the DATA ACL */
{
- if (!(mbox_file = spool_mbox(&mbox_size, NULL)))
+ if (!(mbox_file = spool_mbox(&mbox_size, NULL, NULL)))
{ /* error while spooling */
log_write(0, LOG_MAIN|LOG_PANIC,
"regex acl condition: error while creating mbox spool file");
else
{
clearerr(mime_stream);
- fseek(mime_stream, f_pos, SEEK_SET);
+ if (fseek(mime_stream, f_pos, SEEK_SET) == -1)
+ {
+ log_write(0, LOG_MAIN|LOG_PANIC,
+ "regex acl condition: mime_stream: %s", strerror(errno));
+ clearerr(mime_stream);
+ }
}
return ret;