diff options
author | Hartmut Holzgraefe <hholzgra@php.net> | 2000-08-03 19:26:19 +0000 |
---|---|---|
committer | Hartmut Holzgraefe <hholzgra@php.net> | 2000-08-03 19:26:19 +0000 |
commit | 9cd387439e4515376cf22613467e16d183eff362 (patch) | |
tree | 0b21c7ef96dc254d0dd86068498efe413d4704fd /ext/standard/mail.c | |
parent | fda23fc253bb8cde0bbf26e2ba91848440f47530 (diff) | |
download | php-git-9cd387439e4515376cf22613467e16d183eff362.tar.gz |
evaluate sendmail exit status, fixes unix side of bug #5630
Diffstat (limited to 'ext/standard/mail.c')
-rw-r--r-- | ext/standard/mail.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/standard/mail.c b/ext/standard/mail.c index 16753a7c5c..d4cb79d2fc 100644 --- a/ext/standard/mail.c +++ b/ext/standard/mail.c @@ -25,6 +25,7 @@ #include "ext/standard/info.h" #if !defined(PHP_WIN32) #include "build-defs.h" +#include <sysexits.h> #endif #include "php_mail.h" #include "php_ini.h" @@ -151,7 +152,7 @@ int php_mail(char *to, char *subject, char *message, char *headers) } fprintf(sendmail, "\n%s\n", message); ret = pclose(sendmail); - if (ret == -1) { + if ((ret != EX_OK)&&(ret != EX_TEMPFAIL)) { return 0; } else { return 1; |