1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00

win32/sendmail.c: remove mailRPath parameter that is always NULL

This commit is contained in:
Gina Peter Banyard
2025-12-24 18:35:15 +01:00
parent 4dad723c41
commit 6f28370d2f
3 changed files with 4 additions and 6 deletions

View File

@@ -543,7 +543,7 @@ PHPAPI bool php_mail(const char *to, const char *subject, const char *message, c
char *tsm_errmsg = NULL;
/* handle old style win smtp sending */
if (TSendMail(INI_STR("SMTP"), &tsm_err, &tsm_errmsg, hdr, subject, to, message, NULL, NULL, NULL) == FAILURE) {
if (TSendMail(INI_STR("SMTP"), &tsm_err, &tsm_errmsg, hdr, subject, to, message, NULL, NULL) == FAILURE) {
if (tsm_errmsg) {
php_error_docref(NULL, E_WARNING, "%s", tsm_errmsg);
efree(tsm_errmsg);

View File

@@ -186,7 +186,7 @@ static zend_string *php_win32_mail_trim_header(const char *header)
//*********************************************************************
PHPAPI int TSendMail(const char *host, int *error, char **error_message,
const char *headers, const char *Subject, const char *mailTo, const char *data,
char *mailCc, char *mailBcc, char *mailRPath)
char *mailCc, char *mailBcc)
{
int ret;
char *RPath = NULL;
@@ -216,9 +216,7 @@ PHPAPI int TSendMail(const char *host, int *error, char **error_message,
}
/* Fall back to sendmail_from php.ini setting */
if (mailRPath && *mailRPath) {
RPath = estrdup(mailRPath);
} else if (INI_STR("sendmail_from")) {
if (INI_STR("sendmail_from")) {
RPath = estrdup(INI_STR("sendmail_from"));
} else if (headers_lc) {
int found = 0;

View File

@@ -34,7 +34,7 @@
PHPAPI int TSendMail(const char *host, int *error, char **error_message,
const char *headers, const char *Subject, const char *mailTo, const char *data,
char *mailCc, char *mailBcc, char *mailRPath);
char *mailCc, char *mailBcc);
PHPAPI void TSMClose(void);
PHPAPI const char *GetSMErrorText(int index);
#endif /* sendmail_h */