This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
fixeria gerrit-no-reply at lists.osmocom.orgfixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/22758 )
Change subject: tlv: add msgb_tv32_put(), similar to msgb_tv16_put()
......................................................................
tlv: add msgb_tv32_put(), similar to msgb_tv16_put()
Change-Id: I11301b20038aa5d90d46d968f7eda3d53b560022
---
M include/osmocom/gsm/tlv.h
1 file changed, 10 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/58/22758/1
diff --git a/include/osmocom/gsm/tlv.h b/include/osmocom/gsm/tlv.h
index fe057f4..0d0cdce 100644
--- a/include/osmocom/gsm/tlv.h
+++ b/include/osmocom/gsm/tlv.h
@@ -414,6 +414,16 @@
return tv16_put(buf, tag, val);
}
+/*! put (append) a TV32 field to a \ref msgb
+ * \returns pointer to first byte after newly-put information */
+static inline uint8_t *msgb_tv32_put(struct msgb *msg, uint8_t tag, uint32_t val)
+{
+ uint8_t *buf = msgb_put(msg, 1 + 4);
+ *buf++ = tag;
+ osmo_store32be(val, buf);
+ return msgb->tail;
+}
+
/*! push (prepend) a TLV field to a \ref msgb
* \returns pointer to first byte of newly-pushed information */
static inline uint8_t *msgb_tlv_push(struct msgb *msg, uint8_t tag, uint8_t len, const uint8_t *val)
--
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/22758
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I11301b20038aa5d90d46d968f7eda3d53b560022
Gerrit-Change-Number: 22758
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210206/65bbab8a/attachment.htm>