neels has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-sip-connector/+/34409?usp=email )

Change subject: drop misleading error message
......................................................................

drop misleading error message

call_sip_create() returns NULL only when memory allocation failed. Do
not log "No supported codec", just assert that a call was allocated,
like we usually do in such cases.

Related: SYS#5066
Change-Id: Id7fd16b92bbd10e886892d0c425cf1bc5d5429cf
---
M src/sip.c
1 file changed, 15 insertions(+), 6 deletions(-)

Approvals:
  pespin: Looks good to me, approved
  Jenkins Builder: Verified




diff --git a/src/sip.c b/src/sip.c
index ca8f4ba..61c7cbd 100644
--- a/src/sip.c
+++ b/src/sip.c
@@ -137,12 +137,7 @@
        }

        call = call_sip_create();
-       if (!call) {
-               LOGP(DSIP, LOGL_ERROR, "No supported codec.\n");
-               nua_respond(nh, SIP_500_INTERNAL_SERVER_ERROR, TAG_END());
-               nua_handle_destroy(nh);
-               return;
-       }
+       OSMO_ASSERT(call);

        /* Decode Decode the Global Call Reference (if present) */
        if (xgcr_hdr_present) {

--
To view, visit https://gerrit.osmocom.org/c/osmo-sip-connector/+/34409?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-sip-connector
Gerrit-Branch: master
Gerrit-Change-Id: Id7fd16b92bbd10e886892d0c425cf1bc5d5429cf
Gerrit-Change-Number: 34409
Gerrit-PatchSet: 1
Gerrit-Owner: neels <[email protected]>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: neels <[email protected]>
Gerrit-Reviewer: pespin <[email protected]>
Gerrit-MessageType: merged

Reply via email to