mirror of git://git.sysmocom.de/ofono
stkutil: Add polling off proactive command parser
This commit is contained in:
parent
48bc1c3575
commit
0dc5c5df6f
|
@ -2561,6 +2561,18 @@ static gboolean parse_refresh(struct stk_command *command,
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
static gboolean parse_polling_off(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;
|
||||
}
|
||||
|
||||
struct stk_command *stk_command_new_from_pdu(const unsigned char *pdu,
|
||||
unsigned int len)
|
||||
{
|
||||
|
@ -2652,6 +2664,9 @@ struct stk_command *stk_command_new_from_pdu(const unsigned char *pdu,
|
|||
case STK_COMMAND_TYPE_REFRESH:
|
||||
ok = parse_refresh(command, &iter);
|
||||
break;
|
||||
case STK_COMMAND_TYPE_POLLING_OFF:
|
||||
ok = parse_polling_off(command, &iter);
|
||||
break;
|
||||
default:
|
||||
ok = FALSE;
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue