diff --git a/src/mod/applications/mod_conference/conference_cdr.c b/src/mod/applications/mod_conference/conference_cdr.c index fee5308af6..83ba8ee579 100644 --- a/src/mod/applications/mod_conference/conference_cdr.c +++ b/src/mod/applications/mod_conference/conference_cdr.c @@ -488,6 +488,8 @@ cJSON *conference_cdr_json_render(conference_obj_t *conference, cJSON *req) void conference_cdr_del(conference_member_t *member) { + if (!member->cdr_node) return; + if (member->channel) { switch_channel_get_variables(member->channel, &member->cdr_node->var_event); } @@ -504,6 +506,8 @@ void conference_cdr_add(conference_member_t *member) switch_caller_profile_t *cp; switch_channel_t *channel; + if (zstr(member->conference->log_dir) && (member->conference->cdr_event_mode == CDRE_NONE)) return; + np = switch_core_alloc(member->conference->pool, sizeof(*np)); np->next = member->conference->cdr_nodes; @@ -535,6 +539,8 @@ void conference_cdr_rejected(conference_obj_t *conference, switch_channel_t *cha conference_cdr_reject_t *rp; switch_caller_profile_t *cp; + if (zstr(conference->log_dir) && (conference->cdr_event_mode == CDRE_NONE)) return; + rp = switch_core_alloc(conference->pool, sizeof(*rp)); rp->next = conference->cdr_rejected;