FreeCalypso > hg > freecalypso-tools
changeset 339:7f8f446db97e
sms-pdu-decode: fixed bug in the decoding of From/To address fields
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Sun, 04 Feb 2018 06:19:33 +0000 |
parents | 97a72ec0a6c1 |
children | 88fb194b4b61 |
files | uptools/sms-pdu-decode/sms-pdu-decode.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/uptools/sms-pdu-decode/sms-pdu-decode.c Sun Feb 04 06:05:04 2018 +0000 +++ b/uptools/sms-pdu-decode/sms-pdu-decode.c Sun Feb 04 06:19:33 2018 +0000 @@ -76,7 +76,7 @@ printf("Decode-Error: %s address > 20 digits\n", direction); return(-1); } - addr_field_len = ((pdu[pdu_ptr] + 1) >> 2) + 2; + addr_field_len = ((pdu[pdu_ptr] + 1) >> 1) + 2; if (pdu_ptr + addr_field_len > pdu_length) { printf("Decode-Error: %s address goes past PDU end\n", direction);