]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
fix trivial bug in ooh323_indicate on AST_CONTROL_SRC...
authorAlexandr Anikin <may@telecom-service.ru>
Sat, 9 Apr 2011 20:56:17 +0000 (20:56 +0000)
committerAlexandr Anikin <may@telecom-service.ru>
Sat, 9 Apr 2011 20:56:17 +0000 (20:56 +0000)
check p->rtp is not null

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@313142 65c4cc65-6c06-0410-ace0-fbb531ad65f3

addons/chan_ooh323.c

index 8af04fd37eb750fc01ceca3b985a802bd14de3fa..9e933fd2d05ce6956ce19247c90ca2104078ee51 100644 (file)
@@ -1256,10 +1256,14 @@ static int ooh323_indicate(struct ast_channel *ast, int condition, const void *d
            }
         break;
        case AST_CONTROL_SRCUPDATE:
-               ast_rtp_instance_update_source(p->rtp);
+               if (p->rtp) {
+                       ast_rtp_instance_update_source(p->rtp);
+               }
                break;
        case AST_CONTROL_SRCCHANGE:
-               ast_rtp_instance_change_source(p->rtp);
+               if (p->rtp) {
+                       ast_rtp_instance_change_source(p->rtp);
+               }
                break;
        case AST_CONTROL_CONNECTED_LINE:
                if (!ast->connected.id.name.valid