Re: When no MTA is installed, How to send an email with a cronjob?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Sun, 21 Jul 2013 17:28:04 -0400
Fred Smith wrote:

> > and it has a queue or is it so simple-minded only to work if
> > all is perfect and if the smtp server it uses is not reachable
> > messages are silently lost?

This is how I have implemented a "retry" using the cleancode-email program that
I mentioned earlier today.  


for(;;)
			{
			FILE *capturestderr;
			system(temp);
			capturestderr=openfile(STDERRCAPTURE,"r");
			fseek(capturestderr,0L,SEEK_END);
			if (ftell(capturestderr))
				{
				logtime(log);
				fprintf(log,"%s -- %s ** SEND FAILED ** on
EMAIL MAILOUT, retrying\n",subscription.name,subscription.email); closefile
(capturestderr); sleep(2);
				}
			else
				{
				closefile(capturestderr);
				break;
				}
			}
		remove(STDERRCAPTURE);

-- 
MELVILLE THEATRE ~ Real D 3D Digital Cinema ~ www.melvilletheatre.com
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos




[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux