Change in osmo-ttcn3-hacks[master]: bts: move f_pad_oct() to Osmocom_Types as it's generally useful

Harald Welte gerrit-no-reply at lists.osmocom.org
Fri May 31 11:21:47 UTC 2019


Harald Welte has submitted this change and it was merged. ( https://gerrit.osmocom.org/14277 )

Change subject: bts: move f_pad_oct() to Osmocom_Types as it's generally useful
......................................................................

bts: move f_pad_oct() to Osmocom_Types as it's generally useful

Change-Id: I4df99e5612c67006eb2998529425956fb4a664af
---
M bts/BTS_Tests.ttcn
M library/Osmocom_Types.ttcn
2 files changed, 8 insertions(+), 8 deletions(-)

Approvals:
  Jenkins Builder: Verified
  Vadim Yanitskiy: Looks good to me, approved



diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn
index 0506e64..5481838 100644
--- a/bts/BTS_Tests.ttcn
+++ b/bts/BTS_Tests.ttcn
@@ -3676,14 +3676,6 @@
 	setverdict(pass);
 }
 
-private function f_pad_oct(octetstring str, integer len, OCT1 pad) return octetstring {
-	var integer strlen := lengthof(str);
-	for (var integer i := 0; i < len-strlen; i := i+1) {
-		str := str & pad;
-	}
-	return str;
-}
-
 /* Send PAGING via RSL, expect it to shw up on PCU socket */
 testcase TC_pcu_paging_from_rsl() runs on test_CT {
 	f_init_pcu_test();
diff --git a/library/Osmocom_Types.ttcn b/library/Osmocom_Types.ttcn
index ffd5df5..046a9ea 100644
--- a/library/Osmocom_Types.ttcn
+++ b/library/Osmocom_Types.ttcn
@@ -162,5 +162,13 @@
 	return ret;
 }
 
+function f_pad_oct(octetstring str, integer len, OCT1 pad) return octetstring {
+	var integer strlen := lengthof(str);
+	for (var integer i := 0; i < len-strlen; i := i+1) {
+		str := str & pad;
+	}
+	return str;
+}
+
 
 } with { encode "RAW"; variant "FIELDORDER(msb)" }

-- 
To view, visit https://gerrit.osmocom.org/14277
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I4df99e5612c67006eb2998529425956fb4a664af
Gerrit-Change-Number: 14277
Gerrit-PatchSet: 1
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder (1000002)
Gerrit-Reviewer: Vadim Yanitskiy <axilirator at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190531/256dcd20/attachment.html>


More information about the gerrit-log mailing list