cosmetic: msc_vlr_tests: better place clear_cmd wrap, adjust printed msg

Change-Id: Iec6f03f97803b2604f0094260cba256e72ee67bd
This commit is contained in:
Neels Hofmeyr 2017-07-22 20:29:46 +02:00 committed by Neels Hofmeyr
parent c5aed8c10e
commit 838a381b49
1 changed files with 11 additions and 6 deletions

View File

@ -59,12 +59,6 @@ const char *auth_request_expect_autn;
bool cipher_mode_cmd_sent;
bool cipher_mode_cmd_sent_with_imeisv;
int __real_a_iface_tx_clear_cmd(struct gsm_subscriber_connection *conn);
int __wrap_a_iface_tx_clear_cmd(struct gsm_subscriber_connection *conn)
{
btw("Sending clear command to BSC (conn_id=%u)\n", conn->a.conn_id);
return 0;
}
struct msgb *msgb_from_hex(const char *label, uint16_t size, const char *hex)
{
@ -489,6 +483,17 @@ int __wrap_a_iface_tx_dtap(struct msgb *msg)
return _validate_dtap(msg, RAN_GERAN_A);
}
/* override, requires '-Wl,--wrap=a_iface_tx_clear_cmd' */
int __real_a_iface_tx_clear_cmd(struct gsm_subscriber_connection *conn);
int __wrap_a_iface_tx_clear_cmd(struct gsm_subscriber_connection *conn)
{
btw("BSSAP Clear --%s--> MS", ran_type_name(RAN_GERAN_A));
OSMO_ASSERT(bssap_clear_expected);
bssap_clear_expected = false;
bssap_clear_sent = true;
return 0;
}
static int fake_vlr_tx_lu_acc(void *msc_conn_ref, uint32_t send_tmsi)
{
struct gsm_subscriber_connection *conn = msc_conn_ref;