stas Tue Jul 31 00:32:18 2007 UTC Modified files: /php-src/ext/imap php_imap.c Log: sometimes c-client returns non-null entry with null host http://cvs.php.net/viewvc.cgi/php-src/ext/imap/php_imap.c?r1=1.239&r2=1.240&diff_format=u Index: php-src/ext/imap/php_imap.c diff -u php-src/ext/imap/php_imap.c:1.239 php-src/ext/imap/php_imap.c:1.240 --- php-src/ext/imap/php_imap.c:1.239 Mon May 28 23:33:13 2007 +++ php-src/ext/imap/php_imap.c Tue Jul 31 00:32:18 2007 @@ -26,7 +26,7 @@ | PHP 4.0 updates: Zeev Suraski <[EMAIL PROTECTED]> | +----------------------------------------------------------------------+ */ -/* $Id: php_imap.c,v 1.239 2007/05/28 23:33:13 iliaa Exp $ */ +/* $Id: php_imap.c,v 1.240 2007/07/31 00:32:18 stas Exp $ */ #define IMAP41 @@ -3406,7 +3406,7 @@ addr = NULL; rfc822_parse_adrlist(&addr, tempMailTo, NULL); while (addr) { - if (strcmp(addr->host, ERRHOST) == 0) { + if (addr->host == NULL || strcmp(addr->host, ERRHOST) == 0) { PHP_IMAP_BAD_DEST; } else { bufferTo = safe_erealloc(bufferTo, bt_len, 1, strlen(addr->mailbox)); @@ -3435,7 +3435,7 @@ addr = NULL; rfc822_parse_adrlist(&addr, tempMailTo, NULL); while (addr) { - if (strcmp(addr->host, ERRHOST) == 0) { + if (addr->host == NULL || strcmp(addr->host, ERRHOST) == 0) { PHP_IMAP_BAD_DEST; } else { bufferCc = safe_erealloc(bufferCc, bt_len, 1, strlen(addr->mailbox)); @@ -3461,7 +3461,7 @@ addr = NULL; rfc822_parse_adrlist(&addr, tempMailTo, NULL); while (addr) { - if (strcmp(addr->host, ERRHOST) == 0) { + if (addr->host == NULL || strcmp(addr->host, ERRHOST) == 0) { PHP_IMAP_BAD_DEST; } else { bufferBcc = safe_erealloc(bufferBcc, bt_len, 1, strlen(addr->mailbox));
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php