Change in osmo-mgw[master]: osmux: Define osmux_dummy cfg as boolean
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29647 ) Change subject: osmux: Define osmux_dummy cfg as boolean ...................................................................... osmux: Define osmux_dummy cfg as boolean Change-Id: Ifc3384f9871ddfdbd6282c6e03bf6a2dd8a09a9e --- M include/osmocom/mgcp/mgcp.h M src/libosmo-mgcp/mgcp_osmux.c M src/libosmo-mgcp/mgcp_vty.c 3 files changed, 5 insertions(+), 7 deletions(-) Approvals: Jenkins Builder: Verified laforge: Looks good to me, approved diff --git a/include/osmocom/mgcp/mgcp.h b/include/osmocom/mgcp/mgcp.h index 2005e4f..930557d 100644 --- a/include/osmocom/mgcp/mgcp.h +++ b/include/osmocom/mgcp/mgcp.h @@ -172,10 +172,8 @@ int osmux_batch_size; /* osmux port */ uint16_t osmux_port; - /* Pad circuit with dummy messages until we see the first voice - * message. - */ - uint16_t osmux_dummy; + /* Pad circuit with dummy AMR frames if no payload to transmit is available */ + bool osmux_dummy; /* domain name of the media gateway */ char domain[255+1]; diff --git a/src/libosmo-mgcp/mgcp_osmux.c b/src/libosmo-mgcp/mgcp_osmux.c index 3351650..473e655 100644 --- a/src/libosmo-mgcp/mgcp_osmux.c +++ b/src/libosmo-mgcp/mgcp_osmux.c @@ -544,7 +544,7 @@ */ const struct mgcp_trunk *trunk = conn->conn->endp->trunk; static const uint32_t rtp_ssrc_winlen = UINT32_MAX / (OSMUX_CID_MAX + 1); - uint16_t osmux_dummy = trunk->cfg->osmux_dummy; + bool osmux_dummy = trunk->cfg->osmux_dummy; /* Check if osmux is enabled for the specified connection */ if (conn->osmux.state != OSMUX_STATE_ACTIVATING) { diff --git a/src/libosmo-mgcp/mgcp_vty.c b/src/libosmo-mgcp/mgcp_vty.c index bc2673d..a3af94a 100644 --- a/src/libosmo-mgcp/mgcp_vty.c +++ b/src/libosmo-mgcp/mgcp_vty.c @@ -1639,9 +1639,9 @@ "Disable dummy padding\n") { if (strcmp(argv[0], "on") == 0) - g_cfg->osmux_dummy = 1; + g_cfg->osmux_dummy = true; else if (strcmp(argv[0], "off") == 0) - g_cfg->osmux_dummy = 0; + g_cfg->osmux_dummy = false; return CMD_SUCCESS; } -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29647 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: Ifc3384f9871ddfdbd6282c6e03bf6a2dd8a09a9e Gerrit-Change-Number: 29647 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin@sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge@osmocom.org> Gerrit-Reviewer: pespin <pespin@sysmocom.de> Gerrit-MessageType: merged
participants (1)
-
pespin