diff options
author | Max <msuraev@sysmocom.de> | 2018-01-24 12:33:05 +0100 |
---|---|---|
committer | Max <msuraev@sysmocom.de> | 2018-02-05 13:03:42 +0100 |
commit | 80f4c4eb089e87cb1a9c6843b60836b7a6952164 (patch) | |
tree | a236b8f0384fbd95b91ddcfca5d12b4cc9dab7ac /tests | |
parent | 18c014de6771a3032308123af9969c966e20b7c8 (diff) |
GSUP: change osmo_gsup_encode() return type
* match return type of osmo_gsup_encode() with osmo_gsup_decode() to allow
propagating error to caller
* check return value of osmo_gsup_encode() in GSUP test
* return errors instead of braking app with aseert
Change-Id: Idaa1deecb6d9e15329bd51867b4f6a03357461f0
Related: OS#2864
Diffstat (limited to 'tests')
-rw-r--r-- | tests/gsup/gsup_test.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/gsup/gsup_test.c b/tests/gsup/gsup_test.c index eddcc924..b55f1d97 100644 --- a/tests/gsup/gsup_test.c +++ b/tests/gsup/gsup_test.c @@ -220,7 +220,9 @@ static void test_gsup_messages_dec_enc(void) if (rc < 0) passed = false; - osmo_gsup_encode(msg, &gm); + rc = osmo_gsup_encode(msg, &gm); + if (rc < 0) + passed = false; fprintf(stderr, " generated message: %s\n", msgb_hexdump(msg)); fprintf(stderr, " original message: %s\n", osmo_hexdump(t->data, t->data_len)); |