]> sjero.net Git - linphone/commitdiff
fix crash related to zrtp hello hash when adding video
authorSimon Morlat <simon.morlat@linphone.org>
Thu, 21 Mar 2013 10:13:42 +0000 (11:13 +0100)
committerSimon Morlat <simon.morlat@linphone.org>
Thu, 21 Mar 2013 10:15:11 +0000 (11:15 +0100)
coreapi/linphonecall.c

index e9640701f698c17be5f16086caafbd4e984a9d8f..2770d4ada315a26c9fbf52c7f2f191a34d2fce7b 100644 (file)
@@ -271,7 +271,7 @@ void linphone_call_make_local_media_description(LinphoneCore *lc, LinphoneCall *
                l=make_codec_list(lc,lc->codecs_conf.video_codecs,0,NULL,-1);
                md->streams[1].payloads=l;
                // if ZRTP is enabled, put the hello hash into the audiostream's desc
-               if (call->videostream->ms.zrtp_context!=NULL){
+               if (call->videostream && call->videostream->ms.zrtp_context!=NULL){
                        ortp_zrtp_get_hello_hash(call->videostream->ms.zrtp_context,
                                md->streams[1].zrtp_hello_hash,
                                sizeof(md->streams[1].zrtp_hello_hash));