[asterisk-commits] file: trunk r48595 - /trunk/res/snmp/agent.c
asterisk-commits at lists.digium.com
asterisk-commits at lists.digium.com
Tue Dec 19 15:55:27 MST 2006
Author: file
Date: Tue Dec 19 16:55:26 2006
New Revision: 48595
URL: http://svn.digium.com/view/asterisk?view=rev&rev=48595
Log:
Update res_snmp to use new API declaration of pbx_builtin_serialize_variables (issue #8627 reported by johann8384)
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=48595&r1=48594&r2=48595
==============================================================================
--- trunk/res/snmp/agent.c (original)
+++ trunk/res/snmp/agent.c Tue Dec 19 16:55:26 2006
@@ -198,6 +198,7 @@
struct timeval tval;
u_char *ret;
int i, bit;
+ struct ast_str *out = ast_str_alloca(2048);
if (header_simple_table(vp, name, length, exact, var_len, write_method, ast_active_channels()))
return NULL;
@@ -478,9 +479,9 @@
ret = (u_char *)&long_ret;
break;
case ASTCHANVARIABLES:
- if (pbx_builtin_serialize_variables(chan, string_ret, sizeof(string_ret))) {
- *var_len = strlen(string_ret);
- ret = (u_char *)string_ret;
+ if (pbx_builtin_serialize_variables(chan, &out)) {
+ *var_len = strlen(out->str);
+ ret = (u_char *)out->str;
}
else
ret = NULL;
More information about the asterisk-commits
mailing list