diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-12-31 17:06:09 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-12-31 17:06:09 +0000 |
commit | 1543c98d38ffb84a1e405081436d0a25bee713a6 (patch) | |
tree | 0ba89690e98dea7d08acbd89f3a6d6eb5719fe7c /contrib | |
parent | 644549aa6326a1c04828d2803553a0f248755e3c (diff) | |
parent | df353b050f279d55e9164f9b39837972c900af2f (diff) | |
download | rspamd-1543c98d38ffb84a1e405081436d0a25bee713a6.tar.gz rspamd-1543c98d38ffb84a1e405081436d0a25bee713a6.zip |
Merge pull request #444 from lzmths/master
Refactoring conditional directives that break parts of statements.
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/exim/local_scan.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/contrib/exim/local_scan.c b/contrib/exim/local_scan.c index cffe9de29..20d3ba246 100644 --- a/contrib/exim/local_scan.c +++ b/contrib/exim/local_scan.c @@ -331,6 +331,7 @@ int GetAndTransferMessage (int fd, char *sFile) char answ [4]; int iStatus; int Len, ccnt; + int test; iStatus = GetFiles ((char *)sFile, fd); @@ -344,10 +345,11 @@ int GetAndTransferMessage (int fd, char *sFile) for (ccnt = 0; ccnt <= MAX_FAILS_C; ccnt ++) { #ifdef RSPAM_UNIXSOCKET - if (connect (sock, (struct sockaddr *) &ssun, sizeof (struct sockaddr_un)) < 0) + test = connect (sock, (struct sockaddr *) &ssun, sizeof (struct sockaddr_un)) < 0; #else - if (connect (sock, (struct sockaddr *) &ssin, sizeof (struct sockaddr_in)) < 0) + test = connect (sock, (struct sockaddr *) &ssin, sizeof (struct sockaddr_in)) < 0; #endif + if (test) { if (ccnt < MAX_FAILS_C) usleep (1000); |