small changes to avoiding 'freeing unused memory...'
authorAlexandr Anikin <may@telecom-service.ru>
Sun, 23 May 2010 18:23:38 +0000 (18:23 +0000)
committerAlexandr Anikin <may@telecom-service.ru>
Sun, 23 May 2010 18:23:38 +0000 (18:23 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@265227 65c4cc65-6c06-0410-ace0-fbb531ad65f3

addons/chan_ooh323.c

index fdb2dfc..0024b59 100644 (file)
@@ -1238,11 +1238,13 @@ static int ooh323_indicate(struct ast_channel *ast, int condition, const void *d
        case AST_CONTROL_SRCCHANGE:
                ast_rtp_instance_change_source(p->rtp);
                break;
-      case AST_CONTROL_CONNECTED_LINE:
-               if (gH323Debug)
-                       ast_log(LOG_DEBUG, "Sending connected line info for %s (%s)\n",
+               case AST_CONTROL_CONNECTED_LINE:
+               if (!ast_strlen_zero(ast->connected.id.name)) {
+                       if (gH323Debug)
+                               ast_log(LOG_DEBUG, "Sending connected line info for %s (%s)\n",
                                callToken, ast->connected.id.name);
-               ooSetANI(callToken, ast->connected.id.name);
+                       ooSetANI(callToken, ast->connected.id.name);
+               }
                break;
 
       case AST_CONTROL_T38_PARAMETERS: