From 582e645a989208e67c0fd6edbe93a3873d6bda26 Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Mon, 8 Apr 2019 14:34:17 -0400 Subject: [PATCH] fix missing recording_on flag set reported in #721 Change-Id: I273b4d7c1ba167058366e4c36e5a392b7c734cf2 --- daemon/recording.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/daemon/recording.c b/daemon/recording.c index 4623475ee..69be74082 100644 --- a/daemon/recording.c +++ b/daemon/recording.c @@ -328,10 +328,14 @@ void detect_setup_recording(struct call *call, const str *recordcall, str *metad if (!recordcall || !recordcall->s) return; - if (!str_cmp(recordcall, "yes") || !str_cmp(recordcall, "on")) + if (!str_cmp(recordcall, "yes") || !str_cmp(recordcall, "on")) { + call->recording_on = 1; recording_start(call, NULL, NULL); - else if (!str_cmp(recordcall, "no") || !str_cmp(recordcall, "off")) + } + else if (!str_cmp(recordcall, "no") || !str_cmp(recordcall, "off")) { + call->recording_on = 0; recording_stop(call); + } else ilog(LOG_INFO, "\"record-call\" flag "STR_FORMAT" is invalid flag.", STR_FMT(recordcall)); }