diff --git a/openbsc/src/osmo-bsc/osmo_bsc_filter.c b/openbsc/src/osmo-bsc/osmo_bsc_filter.c index 5ad9fd7..6b15886 100644 --- a/openbsc/src/osmo-bsc/osmo_bsc_filter.c +++ b/openbsc/src/osmo-bsc/osmo_bsc_filter.c @@ -47,7 +47,7 @@ static void handle_lu_request(struct gsm_subscriber_connection *conn, gsm48_generate_lai(&lai, net->country_code, net->network_code, conn->bts->location_area_code); - if (memcmp(&lai, &lu->lai, sizeof(lai)) != 0) { + if (memcmp(&lai, &lu->lai, sizeof(lai))) { LOGP(DMSC, LOGL_DEBUG, "Marking con for welcome USSD.\n"); conn->sccp_con->new_subscriber = 1; } @@ -314,13 +314,10 @@ static int bsc_patch_mm_info(struct gsm_subscriber_connection *conn, static int has_core_identity(struct osmo_msc_data *msc) { - if (msc->core_mnc != -1) - return 1; - if (msc->core_mcc != -1) - return 1; - if (msc->core_lac != -1) - return 1; - if (msc->core_ci != -1) + if ((msc->core_mnc != -1) || + (msc->core_mcc != -1) || + (msc->core_lac != -1) || + (msc->core_ci != -1)) return 1; return 0; } @@ -367,7 +364,6 @@ int bsc_scan_msc_msg(struct gsm_subscriber_connection *conn, struct msgb *msg) if (conn->sccp_con->new_subscriber) return send_welcome_ussd(conn); - return 0; } else if (mtype == GSM48_MT_MM_INFO) { bsc_patch_mm_info(conn, &gh->data[0], length); }