summaryrefslogtreecommitdiff
path: root/ext/snmp
diff options
context:
space:
mode:
authorHarrie Hazewinkel <harrie@php.net>2002-11-11 18:45:50 +0000
committerHarrie Hazewinkel <harrie@php.net>2002-11-11 18:45:50 +0000
commite1f884c4bc6cfaa3363c52dc5eb4717378ece14c (patch)
tree4512f775e1029a1b8365b1404dd5029805029615 /ext/snmp
parent155c453138dba53cbec6694a7d0d55e17331083a (diff)
downloadphp-git-e1f884c4bc6cfaa3363c52dc5eb4717378ece14c.tar.gz
Fixing the php_info function.
Print UCD-SNMP when UCD-SNMP is used. Print NET-SNMP when NET-SNMP is used.
Diffstat (limited to 'ext/snmp')
-rw-r--r--ext/snmp/snmp.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c
index 5a0ee9dffe..0ecf15043f 100644
--- a/ext/snmp/snmp.c
+++ b/ext/snmp/snmp.c
@@ -75,7 +75,6 @@
#ifdef HAVE_NET_SNMP
#include <net-snmp/net-snmp-config.h>
#include <net-snmp/net-snmp-includes.h>
-#define VersionInfo NetSnmpVersionInfo
#else
#ifdef HAVE_DEFAULT_STORE_H
#include "default_store.h"
@@ -154,8 +153,13 @@ PHP_MINIT_FUNCTION(snmp)
PHP_MINFO_FUNCTION(snmp)
{
php_info_print_table_start();
+#ifdef HAVE_NET_SNMP
+ php_info_print_table_row(2, "NET-SNMP Support", "enabled");
+ php_info_print_table_row(2, "NET-SNMP Version", netsnmp_get_version());
+#else
php_info_print_table_row(2, "UCD-SNMP Support", "enabled");
php_info_print_table_row(2, "UCD-SNMP Version", VersionInfo);
+#endif
php_info_print_table_end();
}
/* }}} */