From: Chuck Hagenbuch Date: Tue, 22 Aug 2000 02:35:30 +0000 (+0000) Subject: Fix a crash in imap_fetchheader(). FT_PREFETCHTEXT isn't the only flag that X-Git-Tag: PRE_LIBMYSQL_REVERT~9 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3a1b4fda7eec68eace9f77556b3e3a84e178644d;p=php Fix a crash in imap_fetchheader(). FT_PREFETCHTEXT isn't the only flag that you can pass to mail_fetchheader_full(). --- diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c index 941b2aa948..d1432e7fa8 100644 --- a/ext/imap/php_imap.c +++ b/ext/imap/php_imap.c @@ -2664,7 +2664,7 @@ PHP_FUNCTION(imap_fetchheader) RETVAL_STRINGL(tempstring,(hlen+blen+1),1); efree(tempstring); } else { - RETVAL_STRING(mail_fetchheader_full(imap_le_struct->imap_stream, Z_LVAL_PP(msgno), NIL, NIL, NIL), 1); + RETVAL_STRING(mail_fetchheader_full(imap_le_struct->imap_stream, Z_LVAL_PP(msgno), NIL, NIL, (myargc == 3 ? Z_LVAL_PP(flags) : NIL)), 1); } } /* }}} */