summaryrefslogtreecommitdiffstats
path: root/tests/ussd
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2010-10-11 08:49:27 +0200
committerHolger Hans Peter Freyther <zecke@selfish.org>2010-10-11 09:26:19 +0200
commitf632371b7623dc747ae338d02f2484c069c76c84 (patch)
treed5c6a85a69476f4b14a55ff14070aae067dc6f47 /tests/ussd
parentc88a44f493d594acdb5d9240855678c34ede2a88 (diff)
ussd: Verify that parsing is stil working and print the decoded text.
Diffstat (limited to 'tests/ussd')
-rw-r--r--tests/ussd/ussd_test.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/ussd/ussd_test.c b/tests/ussd/ussd_test.c
index 6680e63c..bddbbcb7 100644
--- a/tests/ussd/ussd_test.c
+++ b/tests/ussd/ussd_test.c
@@ -66,9 +66,14 @@ static int parse_mangle_ussd(const uint8_t *_data, int len)
int main(int argc, char **argv)
{
+ struct ussd_request req;
const int size = sizeof(ussd_request);
int i;
+ gsm0480_decode_ussd_request((struct gsm48_hdr *) ussd_request, size, &req);
+ printf("Tested if it still works. Text was: %s\n", req.text);
+
+
printf("Testing parsing a USSD request and truncated versions\n");
for (i = size; i > sizeof(struct gsm48_hdr); --i) {