[svn-commits] branch kpfleming/chanfunc r9476 - /team/kpfleming/chanfunc/funcs/func_channel.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Fri Feb 10 20:44:24 MST 2006


Author: kpfleming
Date: Fri Feb 10 21:44:23 2006
New Revision: 9476

URL: http://svn.digium.com/view/asterisk?rev=9476&view=rev
Log:
no guarantee a channel will have a zone...

Modified:
    team/kpfleming/chanfunc/funcs/func_channel.c

Modified: team/kpfleming/chanfunc/funcs/func_channel.c
URL: http://svn.digium.com/view/asterisk/team/kpfleming/chanfunc/funcs/func_channel.c?rev=9476&r1=9475&r2=9476&view=diff
==============================================================================
--- team/kpfleming/chanfunc/funcs/func_channel.c (original)
+++ team/kpfleming/chanfunc/funcs/func_channel.c Fri Feb 10 21:44:23 2006
@@ -48,7 +48,7 @@
                 ast_copy_string(buf, ast_getformatname(chan->readformat), len);
         else if (!strcasecmp(data, "audiowriteformat"))
                 ast_copy_string(buf, ast_getformatname(chan->writeformat), len);
-        else if (!strcasecmp(data, "tonezone"))
+        else if (!strcasecmp(data, "tonezone") && chan->zone)
                 ast_copy_string(buf, chan->zone->country, len);
 
 	return buf;



More information about the svn-commits mailing list