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/osmo-ttcn3-hacks/+/24839 )
Change subject: library/RSL_Types: use OCT4 for local/remote address fields
......................................................................
library/RSL_Types: use OCT4 for local/remote address fields
This way functions like f_inet_addr() and f_inet6_addr() can be
used directly without converting between bytes and integers.
Change-Id: I389a8cb95c025c9dddc751789223621c15d9b48f
---
M bts/BTS_Tests.ttcn
M library/RSL_Types.ttcn
2 files changed, 11 insertions(+), 11 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/39/24839/1
diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn
index 06085c6..a7fdf16 100644
--- a/bts/BTS_Tests.ttcn
+++ b/bts/BTS_Tests.ttcn
@@ -4611,7 +4611,7 @@
private function f_TC_ipa_crcx_mdcx_dlcx_not_active(charstring id) runs on ConnHdlr {
f_rsl_transceive(ts_RSL_IPA_CRCX(g_chan_nr), tr_RSL_IPA_CRCX_ACK(g_chan_nr, ?, ?, ?),
"IPA CRCX ACK");
- var uint32_t remote_ip := f_rnd_int(c_UINT32_MAX);
+ var OCT4 remote_ip := f_rnd_octstring(4);
var uint16_t remote_port := f_rnd_int(c_UINT16_MAX);
var uint7_t rtp_pt2 := f_rnd_int(127);
var uint16_t fake_conn_id := 23; /* we're too lazy to read it out from the CRCX ACK above */
@@ -4632,7 +4632,7 @@
private function f_TC_ipa_crcx_mdcx_mdcx_dlcx_not_active(charstring id) runs on ConnHdlr {
f_rsl_transceive(ts_RSL_IPA_CRCX(g_chan_nr), tr_RSL_IPA_CRCX_ACK(g_chan_nr, ?, ?, ?),
"IPA CRCX ACK");
- var uint32_t remote_ip := f_rnd_int(c_UINT32_MAX);
+ var OCT4 remote_ip := f_rnd_octstring(4);
var uint16_t remote_port := f_rnd_int(c_UINT16_MAX);
var uint7_t rtp_pt2 := f_rnd_int(127);
var uint16_t fake_conn_id := 23; /* we're too lazy to read it out from the CRCX ACK above */
@@ -4640,7 +4640,7 @@
tr_RSL_IPA_MDCX_ACK(g_chan_nr, ?, ?, ?, rtp_pt2),
"IPA MDCX ACK");
/* Second MDCX */
- remote_ip := f_rnd_int(c_UINT32_MAX);
+ remote_ip := f_rnd_octstring(4);
remote_port := f_rnd_int(c_UINT16_MAX);
f_rsl_transceive(ts_RSL_IPA_MDCX(g_chan_nr, fake_conn_id, remote_ip, remote_port, rtp_pt2),
tr_RSL_IPA_MDCX_ACK(g_chan_nr, ?, ?, ?, rtp_pt2),
diff --git a/library/RSL_Types.ttcn b/library/RSL_Types.ttcn
index 4e25189..aa206a3 100644
--- a/library/RSL_Types.ttcn
+++ b/library/RSL_Types.ttcn
@@ -919,8 +919,8 @@
uint16_t ipa_conn_id,
uint16_t ipa_local_port,
uint16_t ipa_remote_port,
- uint32_t ipa_local_ip,
- uint32_t ipa_remote_ip,
+ OCT4 ipa_local_ip,
+ OCT4 ipa_remote_ip,
uint8_t ipa_rtp_pt,
uint8_t ipa_rtp_pt2,
RSL_IE_IPA_ConnectionStats ipa_stats,
@@ -2005,7 +2005,7 @@
}
template (value) RSL_Message
ts_RSL_IPA_CRCX(template (value) RslChannelNr chan_nr,
- template (value) uint32_t remote_ip := oct2int('7F000001'O),
+ template (value) OCT4 remote_ip := '7F000001'O,
template (value) uint16_t remote_port := 6766) := {
msg_disc := ts_RSL_MsgDisc(RSL_MDISC_IPACCESS, false),
msg_type := RSL_MT_IPAC_CRCX,
@@ -2018,7 +2018,7 @@
template (value) RSL_Message ts_RSL_IPA_CRCX_ACK(template (value) RslChannelNr chan_nr,
- uint16_t ipa_conn_id, uint32_t local_ip,
+ uint16_t ipa_conn_id, OCT4 local_ip,
uint16_t local_port, uint7_t rtp_pt2) := {
msg_disc := ts_RSL_MsgDisc(RSL_MDISC_IPACCESS, false),
msg_type := RSL_MT_IPAC_CRCX_ACK,
@@ -2032,7 +2032,7 @@
}
template RSL_Message tr_RSL_IPA_CRCX_ACK(template RslChannelNr chan_nr,
template uint16_t ipa_conn_id,
- template uint32_t local_ip,
+ template OCT4 local_ip,
template uint16_t local_port) := {
msg_disc := tr_RSL_MsgDisc(RSL_MDISC_IPACCESS, false),
msg_type := RSL_MT_IPAC_CRCX_ACK,
@@ -2066,7 +2066,7 @@
template (value) RSL_Message ts_RSL_IPA_MDCX(template (value) RslChannelNr chan_nr,
uint16_t ipa_conn_id,
- uint32_t remote_ip, uint16_t remote_port,
+ OCT4 remote_ip, uint16_t remote_port,
uint7_t rtp_pt2) := {
msg_disc := ts_RSL_MsgDisc(RSL_MDISC_IPACCESS, false),
msg_type := RSL_MT_IPAC_MDCX,
@@ -2092,7 +2092,7 @@
template (value) RSL_Message ts_RSL_IPA_MDCX_ACK(template (value) RslChannelNr chan_nr,
uint16_t ipa_conn_id,
- uint32_t local_ip, uint16_t local_port,
+ OCT4 local_ip, uint16_t local_port,
uint7_t rtp_pt2) := {
msg_disc := ts_RSL_MsgDisc(RSL_MDISC_IPACCESS, false),
msg_type := RSL_MT_IPAC_MDCX_ACK,
@@ -2108,7 +2108,7 @@
}
template RSL_Message tr_RSL_IPA_MDCX_ACK(template RslChannelNr chan_nr,
template uint16_t ipa_conn_id,
- template uint32_t local_ip,
+ template OCT4 local_ip,
template uint16_t local_port,
template uint7_t rtp_pt2) := {
msg_disc := tr_RSL_MsgDisc(RSL_MDISC_IPACCESS, false),
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/24839
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I389a8cb95c025c9dddc751789223621c15d9b48f
Gerrit-Change-Number: 24839
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/20210704/5634eeba/attachment.htm>