From: Russell Bryant Date: Wed, 13 Jun 2007 16:05:22 +0000 (+0000) Subject: The variable used for the return value must be declared as static. I broke X-Git-Tag: 1.6.0-beta1~3^2~2386 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5d350e0f8130baaf78b2b42c297d9ef1514b50f3;p=thirdparty%2Fasterisk.git The variable used for the return value must be declared as static. I broke this when applying the patch, sorry! (issue #9637, jeffg) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@69067 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/res/snmp/agent.c b/res/snmp/agent.c index b282d8b57d..d6c4719ea4 100644 --- a/res/snmp/agent.c +++ b/res/snmp/agent.c @@ -590,14 +590,14 @@ static u_char *ast_var_channel_types_table(struct variable *vp, oid *name, size_ static u_char *ast_var_channel_bridge(struct variable *vp, oid *name, size_t *length, int exact, size_t *var_len, WriteMethod **write_method) { - unsigned long long_ret = 0; + static unsigned long long_ret = 0; struct ast_channel *chan = NULL; if (header_generic(vp, name, length, exact, var_len, write_method)) return NULL; while ((chan = ast_channel_walk_locked(chan))) { - if (ast_bridged_channel(chan) != NULL) + if (ast_bridged_channel(chan)) long_ret++; ast_channel_unlock(chan); }