osmo-mgw: rename struct mgcp_trunk_config and symbol tcfg
rename struct mgcp_trunk_config to struct mgcp_trunk and the related
symbol name "tcfg" to "trunk" in order to better match the reality.
Change-Id: I02889dbf8149e139b1bd0326e13ce4c1aec867d1
Related: OS#2659
diff --git a/src/libosmo-mgcp/mgcp_codec.c b/src/libosmo-mgcp/mgcp_codec.c
index 9e55ab0..3cea495 100644
--- a/src/libosmo-mgcp/mgcp_codec.c
+++ b/src/libosmo-mgcp/mgcp_codec.c
@@ -292,7 +292,7 @@
* We do not compare to the full audio_name because we expect that
* "GSM", "GSM/8000" and "GSM/8000/1" are all compatible when the
* audio name of the codec is set to "GSM" */
- if (sscanf(endp->tcfg->audio_name, "%63[^/]/%*d/%*d", codec_name) < 1)
+ if (sscanf(endp->trunk->audio_name, "%63[^/]/%*d/%*d", codec_name) < 1)
return false;
/* Finally we check if the subtype_name we have generated from the
@@ -302,9 +302,9 @@
return true;
/* FIXME: It is questinable that the method to pick a compatible
- * codec can work properly. Since this useses tcfg->audio_name, as
+ * codec can work properly. Since this useses trunk->audio_name, as
* a reference, which is set to "AMR/8000" permanently.
- * tcfg->audio_name must be updated by the first connection that
+ * trunk->audio_name must be updated by the first connection that
* has been made on an endpoint, so that the second connection
* can make a meaningful decision here */
@@ -335,7 +335,7 @@
for (i = 0; i < rtp->codecs_assigned; i++) {
/* When no transcoding is available, avoid codecs that would
* require transcoding. */
- if (endp->tcfg->no_audio_transcoding && !is_codec_compatible(endp, &rtp->codecs[i])) {
+ if (endp->trunk->no_audio_transcoding && !is_codec_compatible(endp, &rtp->codecs[i])) {
LOGP(DLMGCP, LOGL_NOTICE, "transcoding not available, skipping codec: %d/%s\n",
rtp->codecs[i].payload_type, rtp->codecs[i].subtype_name);
continue;