From 0b05039f0d586175905e3cbcb081581451e7ef51 Mon Sep 17 00:00:00 2001 From: Pau Espin Pedrol Date: Sun, 7 Jan 2018 18:05:22 +0100 Subject: tests: sgsn_test: Define wrap APIs with correct parameters MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes following compilation warnings: osmo-sgsn/tests/sgsn/sgsn_test.c: In function ‘test_gmm_attach_subscr’: osmo-sgsn/tests/sgsn/sgsn_test.c:1110:30: warning: assignment from incompatible pointer type [-Wincompatible-pointer-types] subscr_request_auth_info_cb = my_subscr_request_auth_info; ^ osmo-sgsn/tests/sgsn/sgsn_test.c: In function ‘test_gmm_attach_subscr_fake_auth’: osmo-sgsn/tests/sgsn/sgsn_test.c:1144:30: warning: assignment from incompatible pointer type [-Wincompatible-pointer-types] subscr_request_auth_info_cb = my_subscr_request_auth_info_fake_auth; ^ osmo-sgsn/tests/sgsn/sgsn_test.c: In function ‘test_gmm_attach_subscr_gsup_auth’: osmo-sgsn/tests/sgsn/sgsn_test.c:1275:30: warning: assignment from incompatible pointer type [-Wincompatible-pointer-types] subscr_request_auth_info_cb = my_subscr_request_auth_info_gsup_auth; ^ Change-Id: I5fcb3d460d8becb4cc917fc8d27bfc7e49d50b90 --- tests/sgsn/sgsn_test.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'tests/sgsn') diff --git a/tests/sgsn/sgsn_test.c b/tests/sgsn/sgsn_test.c index 219587a8f..5743fce9d 100644 --- a/tests/sgsn/sgsn_test.c +++ b/tests/sgsn/sgsn_test.c @@ -1095,7 +1095,9 @@ int my_subscr_request_update_location(struct sgsn_mm_ctx *mmctx) { return rc; }; -int my_subscr_request_auth_info(struct sgsn_mm_ctx *mmctx) { +int my_subscr_request_auth_info(struct sgsn_mm_ctx *mmctx, const uint8_t *auts, + const uint8_t *auts_rand) +{ gprs_subscr_update(mmctx->subscr); return 0; }; @@ -1124,7 +1126,8 @@ static void test_gmm_attach_subscr(void) cleanup_test(); } -int my_subscr_request_auth_info_fake_auth(struct sgsn_mm_ctx *mmctx) +int my_subscr_request_auth_info_fake_auth(struct sgsn_mm_ctx *mmctx, const uint8_t *auts, + const uint8_t *auts_rand) { /* Fake an authentication */ OSMO_ASSERT(mmctx->subscr); @@ -1210,7 +1213,8 @@ static void test_gmm_attach_subscr_real_auth(void) static int auth_info_skip = 0; static int upd_loc_skip = 0; -int my_subscr_request_auth_info_gsup_auth(struct sgsn_mm_ctx *mmctx) +int my_subscr_request_auth_info_gsup_auth(struct sgsn_mm_ctx *mmctx, const uint8_t *auts, + const uint8_t *auts_rand) { static const uint8_t send_auth_info_res[] = { 0x0a, @@ -1320,7 +1324,7 @@ int my_gsup_client_send(struct gsup_client *gsupc, struct msgb *msg) case OSMO_GSUP_MSGT_SEND_AUTH_INFO_REQUEST: /* Send SEND_AUTH_INFO_RESULT */ - return my_subscr_request_auth_info_gsup_auth(NULL); + return my_subscr_request_auth_info_gsup_auth(NULL, NULL, NULL); case OSMO_GSUP_MSGT_PURGE_MS_REQUEST: from_peer.message_type = OSMO_GSUP_MSGT_PURGE_MS_RESULT; -- cgit v1.2.3