diff options
author | Pekka Pessi <Pekka.Pessi@nokia.com> | 2010-10-06 17:52:17 +0300 |
---|---|---|
committer | Denis Kenzior <denkenz@gmail.com> | 2010-10-10 06:02:15 -0500 |
commit | e21ad3086f2e5d6312078071fa9a819405109e73 (patch) | |
tree | 978da1f423abd380d32d706a90b69de1e34f5627 /src/voicecall.c | |
parent | b654e723c7002d07f4d702beeb27e325e2996201 (diff) | |
download | ofono-e21ad3086f2e5d6312078071fa9a819405109e73.tar.bz2 |
voicecall: Check dial requests in voicecall_is_busy
Return true if a call is being dialed by stk.
Use __ofono_voicecall_is_busy() in __ofono_voicecall_dial().
Diffstat (limited to 'src/voicecall.c')
-rw-r--r-- | src/voicecall.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/voicecall.c b/src/voicecall.c index 2833e640..e072be87 100644 --- a/src/voicecall.c +++ b/src/voicecall.c @@ -2171,7 +2171,7 @@ int ofono_voicecall_get_next_callid(struct ofono_voicecall *vc) ofono_bool_t __ofono_voicecall_is_busy(struct ofono_voicecall *vc, enum ofono_voicecall_interaction type) { - if (vc->pending) + if (vc->pending || vc->dial_req) return TRUE; switch (type) { @@ -2272,7 +2272,7 @@ int __ofono_voicecall_dial(struct ofono_voicecall *vc, vc->driver->release_all_active == NULL) return -ENOSYS; - if (vc->dial_req || vc->pending) + if (__ofono_voicecall_is_busy(vc, interaction) == TRUE) return -EBUSY; /* @@ -2293,11 +2293,6 @@ int __ofono_voicecall_dial(struct ofono_voicecall *vc, vc->dial_req = req; - if (__ofono_voicecall_is_busy(vc, interaction) == TRUE) { - dial_request_finish(vc, FALSE); - return -EBUSY; - } - switch (interaction) { case OFONO_VOICECALL_INTERACTION_NONE: dial_request(vc); |