aboutsummaryrefslogtreecommitdiffstats
path: root/include/osmocom/gtlv/gtlv_dec_enc.h
diff options
context:
space:
mode:
authorNeels Hofmeyr <nhofmeyr@sysmocom.de>2022-03-14 16:38:15 +0100
committerNeels Hofmeyr <neels@hofmeyr.de>2022-06-16 13:04:33 +0200
commit8b58faa4c2e1b52802293f4dce9fcc8dc3843b47 (patch)
tree45ac008dd575470212b72ac5d52df2cbc04e5d35 /include/osmocom/gtlv/gtlv_dec_enc.h
parente011b04c6b2e31bdc46320e5d8a4f48715681f15 (diff)
libosmo-gtlv: add TLIV capability
During code review, it was indicated that some TLV protocols that we will likely deal with in the near future also employ an I, and instance value of a tag. Add TLIV support. A usage example for a manually implemented TLIV structure is found in tests/libosmo-gtlv/gtlv_test.c. A usage example for a generated TLIV protocol is found in tests/libosmo-gtlv/test_tliv/. Related: SYS#5599 Change-Id: I0a076e54dfba6038cc779cb7c8f3967d212226aa
Diffstat (limited to 'include/osmocom/gtlv/gtlv_dec_enc.h')
-rw-r--r--include/osmocom/gtlv/gtlv_dec_enc.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/osmocom/gtlv/gtlv_dec_enc.h b/include/osmocom/gtlv/gtlv_dec_enc.h
index b861129..132239f 100644
--- a/include/osmocom/gtlv/gtlv_dec_enc.h
+++ b/include/osmocom/gtlv/gtlv_dec_enc.h
@@ -78,8 +78,8 @@ enum osmo_gtlv_coding_nested_ies_ordered {
* that the decoded structs to match the IEs are also generated at the same time and thus always match the message
* definitions. For an example, see tests/libosmo-gtlv/test_gtlv_gen/. */
struct osmo_gtlv_coding {
- /*! the IEI value */
- unsigned int tag;
+ /*! the IEI discriminator, and optional instance number */
+ struct osmo_gtlv_tag_inst ti;
/*! Decoding function callback. Invoked for each defined and present IE encountered in the message.
* Return 0 on success, negative on failure. */