From 35c7dd410f7d09c9d69f86f8d70a786c0f7f25ce Mon Sep 17 00:00:00 2001 From: Dmitriy Paliy Date: Wed, 2 Nov 2011 10:50:17 +0200 Subject: [PATCH] Fix response on AT+CHLD=0 in maemo6 Currently, +CIEV indicator after AT+CHLD=0 command for one active call, one held call, one incoming call scenario is incorrect. callheld=2 according to HFP 1.5 spec., p.70, means 'Call on hold, no active call'. Hence, value 2 cannot be provided in +CIEV if there is an active call. --- audio/telephony-maemo6.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/audio/telephony-maemo6.c b/audio/telephony-maemo6.c index 10967fb21..dd75422eb 100644 --- a/audio/telephony-maemo6.c +++ b/audio/telephony-maemo6.c @@ -1354,12 +1354,16 @@ static void call_set_status(struct csd_call *call, dbus_uint32_t status) break; case CSD_CALL_STATUS_TERMINATED: if (call->on_hold && - !find_call_with_status(CSD_CALL_STATUS_HOLD)) + !find_call_with_status(CSD_CALL_STATUS_HOLD)) { telephony_update_indicator(maemo_indicators, "callheld", EV_CALLHELD_NONE); - else if (callheld == EV_CALLHELD_MULTIPLE && - find_call_with_status(CSD_CALL_STATUS_HOLD)) + return; + } + + if (callheld == EV_CALLHELD_MULTIPLE && + find_call_with_status(CSD_CALL_STATUS_HOLD) && + !find_call_with_status(CSD_CALL_STATUS_ACTIVE)) telephony_update_indicator(maemo_indicators, "callheld", EV_CALLHELD_ON_HOLD); -- 2.47.3