[asterisk-commits] russell: trunk r96743 - /trunk/res/snmp/agent.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Sat Jan 5 17:05:35 CST 2008


Author: russell
Date: Sat Jan  5 17:05:35 2008
New Revision: 96743

URL: http://svn.digium.com/view/asterisk?view=rev&rev=96743
Log:
Convert this file over the new method of getting the Asterisk version.
(I don't have this building on this machine, so caio1982 on IRC is going to
 test it for me.  :) )

Modified:
    trunk/res/snmp/agent.c

Modified: trunk/res/snmp/agent.c
URL: http://svn.digium.com/view/asterisk/trunk/res/snmp/agent.c?view=diff&rev=96743&r1=96742&r2=96743
==============================================================================
--- trunk/res/snmp/agent.c (original)
+++ trunk/res/snmp/agent.c Sat Jan  5 17:05:35 2008
@@ -731,10 +731,13 @@
 
 	switch (vp->magic) {
 	case ASTVERSTRING:
-		*var_len = strlen(ASTERISK_VERSION);
-		return (u_char *)ASTERISK_VERSION;
+	{
+		const char *version = ast_get_version();
+		*var_len = strlen(version);
+		return (u_char *)version;
+	}
 	case ASTVERTAG:
-		long_ret = ASTERISK_VERSION_NUM;
+		sscanf(ast_get_version_num(), "%lu", &long_ret);
 		return (u_char *)&long_ret;
 	default:
 		break;




More information about the asterisk-commits mailing list