---
 src/stk.c |   18 ++++++++++++++++++
 1 files changed, 18 insertions(+), 0 deletions(-)

diff --git a/src/stk.c b/src/stk.c
index 1e4d237..58fdbdf 100644
--- a/src/stk.c
+++ b/src/stk.c
@@ -512,6 +512,24 @@ static void cancel_pending_dtmf(struct ofono_stk *stk)
 
 static void ofono_stk_deactivate_context_cb(int error, void *data)
 {
+       struct ofono_stk *stk = data;
+
+       DBG("");
+
+       if (stk->pending_cmd && stk->pending_cmd->type ==
+                       STK_COMMAND_TYPE_CLOSE_CHANNEL) {
+               stk->bip.channel.status =
+                               STK_CHANNEL_PACKET_DATA_SERVICE_NOT_ACTIVATED;
+
+               if (error < 0)
+                       send_simple_response(stk, STK_RESULT_TYPE_NOT_CAPABLE);
+               else
+                       send_simple_response(stk, STK_RESULT_TYPE_SUCCESS);
+       } else {
+               /* TODO send channel status event */
+       }
+
+       stk->bip.channel.id = 0;
 }
 
 static void stk_close_channel(struct ofono_stk *stk)
-- 
1.7.1

_______________________________________________
ofono mailing list
[email protected]
http://lists.ofono.org/listinfo/ofono

Reply via email to