diff options
author | Anatol Belski <ab@php.net> | 2017-02-01 13:43:33 +0100 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2017-02-01 13:43:33 +0100 |
commit | 8dfa428ccdec0755a8d71b6faeade5ddc0145aab (patch) | |
tree | d0fc6a532a089b521b0dce00ccb6fe55d43c2d50 | |
parent | 15404bda138ec073dec382ad71472f461305921b (diff) | |
download | php-git-8dfa428ccdec0755a8d71b6faeade5ddc0145aab.tar.gz |
fix possible NULL dereference
-rw-r--r-- | win32/sendmail.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/win32/sendmail.c b/win32/sendmail.c index 28befc3f96..d460f22fda 100644 --- a/win32/sendmail.c +++ b/win32/sendmail.c @@ -302,7 +302,7 @@ PHPAPI int TSendMail(char *host, int *error, char **error_message, PW32G(mail_host), !INI_INT("smtp_port") ? 25 : INI_INT("smtp_port")); return FAILURE; } else { - ret = SendText(RPath, Subject, mailTo, mailCc, mailBcc, data, ZSTR_VAL(headers_trim), ZSTR_VAL(headers_lc), error_message); + ret = SendText(RPath, Subject, mailTo, mailCc, mailBcc, data, headers ? ZSTR_VAL(headers_trim) : NULL, headers ? ZSTR_VAL(headers_lc) : NULL, error_message); TSMClose(); if (RPath) { efree(RPath); |