FreeCalypso > hg > freecalypso-tools
comparison uptools/libcoding/gsm7_decode.c @ 804:30fbaa652ea5
pcm-sms-decode & sms-pdu-decode: rm remains of bad chars count
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Thu, 25 Mar 2021 03:26:23 +0000 |
parents | 5637794913a8 |
children |
comparison
equal
deleted
inserted
replaced
803:5637794913a8 | 804:30fbaa652ea5 |
---|---|
7 #include <stdio.h> | 7 #include <stdio.h> |
8 | 8 |
9 extern u_short gsm7_decode_table[128]; | 9 extern u_short gsm7_decode_table[128]; |
10 extern u_short gsm7ext_decode_table[128]; | 10 extern u_short gsm7ext_decode_table[128]; |
11 | 11 |
12 gsm7_to_ascii_or_ext(inbuf, inlen, outbuf, outlenp, ascii_ext, newline_ok, errp) | 12 gsm7_to_ascii_or_ext(inbuf, inlen, outbuf, outlenp, ascii_ext, newline_ok) |
13 u_char *inbuf, *outbuf; | 13 u_char *inbuf, *outbuf; |
14 unsigned inlen, *outlenp, *errp; | 14 unsigned inlen, *outlenp; |
15 { | 15 { |
16 u_char *inp, *endp, *outp; | 16 u_char *inp, *endp, *outp; |
17 unsigned gsm, uni; | 17 unsigned gsm, uni; |
18 int is_ext; | 18 int is_ext; |
19 | 19 |
72 *outp++ = uni; | 72 *outp++ = uni; |
73 } | 73 } |
74 *outp = '\0'; | 74 *outp = '\0'; |
75 if (outlenp) | 75 if (outlenp) |
76 *outlenp = outp - outbuf; | 76 *outlenp = outp - outbuf; |
77 if (errp) | |
78 *errp = 0; | |
79 } | 77 } |