Commit b1663d2c authored by Simon Morlat's avatar Simon Morlat
Browse files

fix potential crash in linphone_call_enable_camera()

parent ba063681
......@@ -1100,7 +1100,8 @@ LinphoneCall *linphone_call_get_replaced_call(LinphoneCall *call){
void linphone_call_enable_camera (LinphoneCall *call, bool_t enable){
if (call->videostream!=NULL && call->videostream->ms.ticker!=NULL){
if ((call->state==LinphoneCallStreamsRunning || call->state==LinphoneCallOutgoingEarlyMedia || call->state==LinphoneCallIncomingEarlyMedia)
&& call->videostream!=NULL ){
LinphoneCore *lc=call->core;
MSWebCam *nowebcam=get_nowebcam_device();
if (call->camera_enabled!=enable && lc->video_conf.device!=nowebcam){
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment