From: Jani Taskinen Date: Mon, 4 Aug 2008 20:54:20 +0000 (+0000) Subject: MFH: proper version check X-Git-Tag: php-5.2.7RC1~148 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=09eebe78d8190ca5655cb5a12c5c734729b8dbae;p=php MFH: proper version check --- diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c index 387fd2f0b9..59660dbddc 100644 --- a/ext/imap/php_imap.c +++ b/ext/imap/php_imap.c @@ -717,23 +717,26 @@ PHP_RSHUTDOWN_FUNCTION(imap) } /* }}} */ - -/* {{{ PHP_MINFO_FUNCTION - */ -PHP_MINFO_FUNCTION(imap) -{ - php_info_print_table_start(); +#if !defined(CCLIENTVERSION) #if HAVE_IMAP2004 - php_info_print_table_row(2, "IMAP c-Client Version", "2004"); +#define CCLIENTVERSION "2004" #elif HAVE_IMAP2001 - php_info_print_table_row(2, "IMAP c-Client Version", "2001"); +#define CCLIENTVERSION "2001" #elif HAVE_IMAP2000 - php_info_print_table_row(2, "IMAP c-Client Version", "2000"); +#define CCLIENTVERSION "2000" #elif defined(IMAP41) - php_info_print_table_row(2, "IMAP c-Client Version", "4.1"); +#define CCLIENTVERSION "4.1" #else - php_info_print_table_row(2, "IMAP c-Client Version", "4.0"); +#define CCLIENTVERSION "4.0" +#endif #endif + +/* {{{ PHP_MINFO_FUNCTION + */ +PHP_MINFO_FUNCTION(imap) +{ + php_info_print_table_start(); + php_info_print_table_row(2, "IMAP c-Client Version", CCLIENTVERSION); #if HAVE_IMAP_SSL php_info_print_table_row(2, "SSL Support", "enabled"); #endif