File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -795,6 +795,22 @@ PHP_MSHUTDOWN_FUNCTION(redis)
795795 return SUCCESS ;
796796}
797797
798+ static const char * get_available_serializers (void ) {
799+ #ifdef HAVE_REDIS_IGBINARY
800+ #ifdef HAVE_REDIS_MSGPACK
801+ return "php, igbinary, msgpack" ;
802+ #else
803+ return "php, igbinary" ;
804+ #endif
805+ #else
806+ #ifdef HAVE_REDIS_MSGPACK
807+ return "php, msgpack" ;
808+ #else
809+ return "php" ;
810+ #endif
811+ #endif
812+ }
813+
798814/**
799815 * PHP_MINFO_FUNCTION
800816 */
@@ -806,11 +822,7 @@ PHP_MINFO_FUNCTION(redis)
806822#ifdef GIT_REVISION
807823 php_info_print_table_row (2 , "Git revision" , "$Id: " GIT_REVISION " $" );
808824#endif
809- #ifdef HAVE_REDIS_IGBINARY
810- php_info_print_table_row (2 , "Available serializers" , "php, igbinary" );
811- #else
812- php_info_print_table_row (2 , "Available serializers" , "php" );
813- #endif
825+ php_info_print_table_row (2 , "Available serializers" , get_available_serializers ());
814826#ifdef HAVE_REDIS_LZF
815827 php_info_print_table_row (2 , "Available compression" , "lzf" );
816828#endif
You can’t perform that action at this time.
0 commit comments