From 9a69e5363ab1c0200e31f6f061490cd350ce4a43 Mon Sep 17 00:00:00 2001 From: Aleksander Morgado Date: Thu, 14 Jun 2018 13:10:38 +0200 Subject: base-call: don't notify a state change if it didn't change --- src/mm-base-call.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/mm-base-call.c b/src/mm-base-call.c index 95ea2d00..6972276a 100644 --- a/src/mm-base-call.c +++ b/src/mm-base-call.c @@ -544,10 +544,13 @@ mm_base_call_change_state (MMBaseCall *self, MMCallState new_state, MMCallStateReason reason) { - int old_state; + MMCallState old_state; old_state = mm_gdbus_call_get_state (MM_GDBUS_CALL (self)); + if (old_state == new_state) + return; + g_object_set (self, "state", new_state, "state-reason", reason, -- cgit v1.2.3-70-g09d2