[SA-exim] Stall Sender files left in input

Marc MERLIN marc at merlins.org
Wed, 17 Jul 2002 08:07:52 -0700


On Wed, Jul 17, 2002 at 08:45:30AM -0600, Craig Coles wrote:
> I've been using the Stall Sender option and have noticed that the files are
> not only saved in /var/spool/exim/SAstallsender but also in
> /var/spool/exim/input (the queue file is).  Is there an option to not save
> the queue file in input?  I am seeing many stalls in the logs and the result
> in SAstallsender, which I can turn off the saving of the files there, but
> what about in input?

Indeed, doing exit in the middle of my code was a bad idea, sorry :-)

I just updated the CVS code to do this instead:
RCS file: /cvsroot/sa-exim/sa-exim/sa-exim.c,v
retrieving revision 1.14
diff -u -r1.14 sa-exim.c
--- sa-exim.c   16 Jul 2002 19:04:05 -0000      1.14
+++ sa-exim.c   17 Jul 2002 15:05:50 -0000
@@ -889,9 +889,9 @@
             * exactly what we're trying to do, so let's override that */
            alarm(0);
            /* Mmmh, unfortunately, exim doesn't seem to realize when the other
-            * side breaks the connection, so we'll sleep for all of 
+            * side breaks the connection until it writes something to it after
             * SAstallsendertime, even if the other side has already 
-            * disconnected.
+            * disconnected earlier
             * Patches to detect that the other side has disconnected are
             * wecome :-) */
            while (SAstallsendertime--)
@@ -899,9 +899,9 @@
                /* I tried to cut the big sleep in slices, but it didn't help */
                sleep(1);
            }
-           /* Let's be rude and die after the timeout */
-           log_write(0, LOG_MAIN, "SA: local_scan stall completed. Committing hara kiri");
-           exit(0);
+           log_write(0, LOG_MAIN, "SA: local_scan stall completed. Sending tempreject");
+           *return_text=string_sprintf("SA: Please try again later");
+           return LOCAL_SCAN_TEMPREJECT;
        }
        else if (dorej && spamvalue > SAdevnull)
        {


Marc
-- 
"A mouse is a device used to point at the xterm you want to type in" - A.S.R.
Microsoft is to operating systems & security ....
                                      .... what McDonalds is to gourmet cooking
Home page: http://marc.merlins.org/   |   Finger marc_f@merlins.org for PGP key