From 144d3733cf391dd999f1a6f6e0c76f8298595846 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Fri, 28 Jul 2017 18:05:45 -0500 Subject: [PATCH] FS-10472: [mod_conference] Crash due to hangup race in conference personal canvas mode -- minor regression --- .../applications/mod_conference/conference_video.c | 13 +------------ .../applications/mod_conference/mod_conference.h | 1 - 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/src/mod/applications/mod_conference/conference_video.c b/src/mod/applications/mod_conference/conference_video.c index f903fb93fd..80c648e93e 100644 --- a/src/mod/applications/mod_conference/conference_video.c +++ b/src/mod/applications/mod_conference/conference_video.c @@ -616,7 +616,6 @@ void conference_video_scale_and_patch(mcu_layer_t *layer, switch_image_t *ximg, double screen_aspect = 0, img_aspect = 0; int x_pos = layer->x_pos; int y_pos = layer->y_pos; - switch_size_t img_addr = 0; switch_frame_geometry_t *use_geometry = &layer->auto_geometry; img_w = layer->screen_w = (uint32_t)(IMG->d_w * layer->geometry.scale / VIDEO_LAYOUT_SCALE); img_h = layer->screen_h = (uint32_t)(IMG->d_h * layer->geometry.hscale / VIDEO_LAYOUT_SCALE); @@ -625,10 +624,7 @@ void conference_video_scale_and_patch(mcu_layer_t *layer, switch_image_t *ximg, screen_aspect = (double) layer->screen_w / layer->screen_h; img_aspect = (double) img->d_w / img->d_h; - img_addr = (switch_size_t)img; - - - if (layer->last_img_addr != img_addr && (layer->geometry.zoom || layer->cam_opts.autozoom || + if ((layer->geometry.zoom || layer->cam_opts.autozoom || layer->cam_opts.autopan || layer->cam_opts.manual_pan || layer->cam_opts.manual_zoom)) { double scale = 1; @@ -911,10 +907,6 @@ void conference_video_scale_and_patch(mcu_layer_t *layer, switch_image_t *ximg, } - - - layer->last_img_addr = img_addr; - } else { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG10, "insert at %d,%d\n", 0, 0); switch_img_patch(IMG, img, 0, 0); @@ -3682,9 +3674,6 @@ void *SWITCH_THREAD_FUNC conference_video_muxing_thread_run(switch_thread_t *thr if (layer && use_img) { switch_img_copy(use_img, &layer->cur_img); - } - - if (layer) { conference_video_scale_and_patch(layer, NULL, SWITCH_FALSE); } diff --git a/src/mod/applications/mod_conference/mod_conference.h b/src/mod/applications/mod_conference/mod_conference.h index 29e065a954..141af9cd31 100644 --- a/src/mod/applications/mod_conference/mod_conference.h +++ b/src/mod/applications/mod_conference/mod_conference.h @@ -480,7 +480,6 @@ typedef struct mcu_layer_s { int last_w; int last_h; uint32_t img_count; - switch_size_t last_img_addr; switch_image_t *img; switch_image_t *cur_img; switch_image_t *overlay_img;