HS/02 Support Avast multiline protoocol, this allows passing flags to
newer versions of the scanner.
+JH/28 Ensure that variables possibly set during message acceptance are marked
+ dead before release of memory in the daemon loop. This stops complaints
+ about them when the debug_store option is enabled. Discovered specifically
+ for sender_rate_period, but applies to a whole set of variables.
+
Exim version 4.90
-----------------
/* Reclaim up the store used in accepting this message */
- return_path = sender_address = NULL;
- authenticated_sender = NULL;
- sending_ip_address = NULL;
- deliver_host_address = deliver_host =
- deliver_domain_orig = deliver_localpart_orig = NULL;
- dnslist_domain = dnslist_matched = NULL;
- callout_address = NULL;
-#ifndef DISABLE_DKIM
- dkim_cur_signer = NULL;
-#endif
- acl_var_m = NULL;
- store_reset(reset_point);
+ {
+ int r = receive_messagecount;
+ BOOL q = queue_only_policy;
+ smtp_reset(reset_point);
+ queue_only_policy = q;
+ receive_messagecount = r;
+ }
/* If queue_only is set or if there are too many incoming connections in
existence, session_local_queue_only will be TRUE. If it is not, check
extern void smtp_message_code(uschar **, int *, uschar **, uschar **, BOOL);
extern void smtp_proxy_tls(uschar *, size_t, int *, int);
extern BOOL smtp_read_response(smtp_inblock *, uschar *, int, int, int);
+extern void smtp_reset(void *);
extern void smtp_respond(uschar *, int, BOOL, uschar *);
extern void smtp_notquit_exit(uschar *, uschar *, uschar *, ...);
extern void smtp_port_for_connect(host_item *, int);
*************************************************/
/* This function is called whenever the SMTP session is reset from
-within either of the setup functions.
+within either of the setup functions; also from the daemon loop.
Argument: the stacking pool storage reset point
Returns: nothing
*/
-static void
+void
smtp_reset(void *reset_point)
{
recipients_list = NULL;
#endif
dnslist_domain = dnslist_matched = NULL;
#ifndef DISABLE_DKIM
-dkim_signers = NULL;
-dkim_disable_verify = FALSE;
-dkim_collect_input = FALSE;
+dkim_cur_signer = dkim_signers = NULL;
+dkim_disable_verify = dkim_collect_input = FALSE;
#endif
dsn_ret = 0;
dsn_envid = NULL;
prdr_requested = FALSE;
#endif
#ifdef SUPPORT_SPF
-spf_header_comment = NULL;
-spf_received = NULL;
-spf_result = NULL;
-spf_smtp_comment = NULL;
+spf_header_comment = spf_received = spf_result = spf_smtp_comment = NULL;
#endif
#ifdef SUPPORT_I18N
message_smtputf8 = FALSE;