diff options
-rw-r--r-- | src/ring-media-channel.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/ring-media-channel.c b/src/ring-media-channel.c index 35aad36..c8c97d8 100644 --- a/src/ring-media-channel.c +++ b/src/ring-media-channel.c @@ -891,8 +891,16 @@ response_to_hold (ModemCall *ci, if (error && priv->hold.requested != -1) { - ring_update_hold (self, - priv->hold.requested ? TP_LOCAL_HOLD_STATE_UNHELD : TP_LOCAL_HOLD_STATE_HELD, + uint8_t next; + + DEBUG ("%s: %s", self->nick, error->message); + + if (priv->hold.requested) + next = TP_LOCAL_HOLD_STATE_UNHELD; + else + next = TP_LOCAL_HOLD_STATE_HELD; + + ring_update_hold (self, next, TP_LOCAL_HOLD_STATE_REASON_RESOURCE_NOT_AVAILABLE); priv->hold.requested = -1; |