Trivial: code simplification, return early
This commit also, (for what it is worth) removes a difference to the same file in openbsc, which I found while looking for changes that affected SMPP delivery. This is essentially a "forward-port" of [1] [1] https://gerrit.osmocom.org/#/c/openbsc/+/3899/ Change-Id: I350c19f5bb70b2656171c096334c2ee83f49df7e
This commit is contained in:
parent
b67131595f
commit
2cad562eb2
|
@ -442,7 +442,9 @@ try_local:
|
|||
|
||||
/* determine gsms->receiver based on dialled number */
|
||||
gsms->receiver = vlr_subscr_find_by_msisdn(net->vlr, gsms->dst.addr, VSUB_USE_SMS_RECEIVER);
|
||||
if (!gsms->receiver) {
|
||||
if (gsms->receiver)
|
||||
return 0;
|
||||
|
||||
#ifdef BUILD_SMPP
|
||||
/* Avoid a second look-up */
|
||||
if (smpp_route_smpp_first()) {
|
||||
|
@ -463,8 +465,6 @@ try_local:
|
|||
rc = GSM411_RP_CAUSE_MO_NUM_UNASSIGNED;
|
||||
rate_ctr_inc(&net->msc_ctrs->ctr[MSC_CTR_SMS_NO_RECEIVER]);
|
||||
#endif
|
||||
} else
|
||||
rc = 0;
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue