Open Source Telephony
 help / color / mirror / Atom feed
From: Yang Gu <yang.gu@intel.com>
To: ofono@ofono.org
Subject: [PATCH 4/7] stkutil: Add parser for more time proactive commands
Date: Tue, 27 Apr 2010 17:47:09 +0800	[thread overview]
Message-ID: <1272361632-21352-4-git-send-email-yang.gu@intel.com> (raw)
In-Reply-To: <1272361632-21352-1-git-send-email-yang.gu@intel.com>

[-- Attachment #1: Type: text/plain, Size: 1089 bytes --]

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

diff --git a/src/stkutil.c b/src/stkutil.c
index ed48db4..2e0c957 100644
--- a/src/stkutil.c
+++ b/src/stkutil.c
@@ -2189,6 +2189,18 @@ static gboolean parse_get_input(struct stk_command *command,
 	return TRUE;
 }
 
+static gboolean parse_more_time(struct stk_command *command,
+					struct comprehension_tlv_iter *iter)
+{
+	if (command->src != STK_DEVICE_IDENTITY_TYPE_UICC)
+		return FALSE;
+
+	if (command->dst != STK_DEVICE_IDENTITY_TYPE_TERMINAL)
+		return FALSE;
+
+	return TRUE;
+}
+
 static void destroy_send_sms(struct stk_command *command)
 {
 	g_free(command->send_sms.alpha_id);
@@ -2303,6 +2315,9 @@ struct stk_command *stk_command_new_from_pdu(const unsigned char *pdu,
 	case STK_COMMAND_TYPE_GET_INPUT:
 		ok = parse_get_input(command, &iter);
 		break;
+	case STK_COMMAND_TYPE_MORE_TIME:
+		ok = parse_more_time(command, &iter);
+		break;
 	case STK_COMMAND_TYPE_SEND_SMS:
 		ok = parse_send_sms(command, &iter);
 		break;
-- 
1.7.0.4


  parent reply	other threads:[~2010-04-27  9:47 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-27  9:47 [PATCH 1/7] stkutil: Move advance of ctlv to parse_dataobj Yang Gu
2010-04-27  9:47 ` [PATCH 2/7] stkutil: Use struct to represent frame id Yang Gu
2010-04-27  9:47 ` [PATCH 3/7] test-stkutil: Refactor the implementation to test display text Yang Gu
2010-04-27  9:47 ` Yang Gu [this message]
2010-04-27  9:47 ` [PATCH 5/7] test-stkutil: Add unit test for more time parser Yang Gu
2010-04-27  9:47 ` [PATCH 6/7] stkutil: Change some dataobj parser to use char * instead of char ** Yang Gu
2010-04-27  9:47 ` [PATCH 7/7] stkutil: Make get inkey parser use its own struct Yang Gu
2010-04-27 14:36 ` [PATCH 1/7] stkutil: Move advance of ctlv to parse_dataobj Denis Kenzior

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1272361632-21352-4-git-send-email-yang.gu@intel.com \
    --to=yang.gu@intel.com \
    --cc=ofono@ofono.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox