aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--openbsc/src/libmgcp/rtp_helper.c3
-rw-r--r--openbsc/tests/mgcp/mgcp_test.c1
2 files changed, 4 insertions, 0 deletions
diff --git a/openbsc/src/libmgcp/rtp_helper.c b/openbsc/src/libmgcp/rtp_helper.c
index a07db3591..aafbbe52d 100644
--- a/openbsc/src/libmgcp/rtp_helper.c
+++ b/openbsc/src/libmgcp/rtp_helper.c
@@ -316,6 +316,9 @@ int rtp_compress(struct mgcp_rtp_compr_state *state, struct msgb *msg,
if (hdr->marker)
marker = 1;
+ state->generated_ssrc = ntohl(hdr->ssrc);
+ state->timestamp = ntohl(hdr->timestamp);
+ state->sequence = ntohs(hdr->sequence);
last_sequence = sequence;
count += 1;
}
diff --git a/openbsc/tests/mgcp/mgcp_test.c b/openbsc/tests/mgcp/mgcp_test.c
index 4927027e8..32f2fd649 100644
--- a/openbsc/tests/mgcp/mgcp_test.c
+++ b/openbsc/tests/mgcp/mgcp_test.c
@@ -251,6 +251,7 @@ static void test_compress_one(const struct estate *edata, char *t)
INIT_LLIST_HEAD(&list);
+ state = edata->state;
if (rtp_decompress(&state, &list, out) != 0) {
fprintf(stderr, "Failed to decompress the code.\n");
abort();