summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSylvain Munaut <tnt@246tNt.com>2009-12-28 00:04:56 +0100
committerHarald Welte <laforge@gnumonks.org>2010-01-07 10:22:23 +0100
commitd316444e1bb7ad5fc5e968b4bccd488022ff2bab (patch)
tree35a5588ac1b060db812cc373dfd5ca5bd213da33
parent90e46f50552267957beef42829426ebb338b92a0 (diff)
rrlp-ephemeris: Properly implement pseudo segmentation flag
See 3GPP TS 44.031 section 2.2/2.3 for a example/description. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
-rw-r--r--rrlp.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/rrlp.c b/rrlp.c
index ad8eb5b..0ff9321 100644
--- a/rrlp.c
+++ b/rrlp.c
@@ -575,6 +575,14 @@ rrlp_gps_assist_pdus(
/* Serialize & Release all PDUs */
for (i=0; i<lst_cnt && i<o_max_pdus; i++) {
+ /* Pseudo segmentation flags */
+ MoreAssDataToBeSent_t *mad = calloc(1, sizeof(*mad));
+ *mad = (i == (lst_cnt-1)) ?
+ MoreAssDataToBeSent_noMoreMessages :
+ MoreAssDataToBeSent_moreMessagesOnTheWay;
+ lst_pdu[i]->component.choice.assistanceData.moreAssDataToBeSent = mad;
+
+ /* Serialization */
// asn_fprint(stdout, &asn_DEF_PDU, lst_pdu[i]);
rv = uper_encode_to_new_buffer(&asn_DEF_PDU, NULL, lst_pdu[i], &o_pdu[i]);
if (rv < 0)