xpp: remove useless sanity check of len field

The packet data length field may have other values in some cases (BRI D
channel).  It is also inherently limited to 3 bits.

Signed-off-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com>
This commit is contained in:
Tzafrir Cohen 2017-03-29 11:33:40 +03:00
parent b8b884d205
commit 6b119e60f5

View File

@ -696,14 +696,8 @@ HANDLER_DEF(GLOBAL, REGISTER_REPLY)
"REGISTER_REPLY: missing card_register_reply()\n");
return -EINVAL;
}
switch (reg->h.bytes) {
case REG_CMD_SIZE(REG):
case REG_CMD_SIZE(RAM):
return CALL_XMETHOD(card_register_reply, xpd, reg);
}
XPD_ERR(xpd, "REGISTER_REPLY: bad packet_len=%d\n", pack->head.packet_len);
return -EINVAL;
}
HANDLER_DEF(GLOBAL, SYNC_REPLY)
{