From 4b3b13e10c164547f014677c0ac1fb137850b387 Mon Sep 17 00:00:00 2001 From: Neels Hofmeyr Date: Tue, 22 Mar 2016 19:19:03 +0100 Subject: [PATCH] fix various compiler warnings sgsn_libgtp.c: missing include, for asn1str_to_u32() iu_cs.c: missing include, for subscr_name() osmo_bsc_vty.c: int/pointer conversions (note: this was discussed on the list to be solved by passing a pointer instead. Until then...) iudummy.c: opaque struct declarations --- openbsc/src/gprs/sgsn_libgtp.c | 2 ++ openbsc/src/libmsc/iu_cs.c | 1 + openbsc/src/osmo-bsc/osmo_bsc_vty.c | 4 ++-- openbsc/tests/libiudummy/iudummy.c | 4 ++++ 4 files changed, 9 insertions(+), 2 deletions(-) diff --git a/openbsc/src/gprs/sgsn_libgtp.c b/openbsc/src/gprs/sgsn_libgtp.c index 3d3173a11..a637086f6 100644 --- a/openbsc/src/gprs/sgsn_libgtp.c +++ b/openbsc/src/gprs/sgsn_libgtp.c @@ -52,6 +52,8 @@ #include +#include + #include #include diff --git a/openbsc/src/libmsc/iu_cs.c b/openbsc/src/libmsc/iu_cs.c index 1b3ce0ab7..8d1878dc3 100644 --- a/openbsc/src/libmsc/iu_cs.c +++ b/openbsc/src/libmsc/iu_cs.c @@ -6,6 +6,7 @@ #include #include #include +#include /* For A-interface see libbsc/bsc_api.c subscr_con_allocate() */ struct gsm_subscriber_connection *subscr_conn_allocate_iu(struct gsm_network *network, diff --git a/openbsc/src/osmo-bsc/osmo_bsc_vty.c b/openbsc/src/osmo-bsc/osmo_bsc_vty.c index d871f015a..c8f0621dc 100644 --- a/openbsc/src/osmo-bsc/osmo_bsc_vty.c +++ b/openbsc/src/osmo-bsc/osmo_bsc_vty.c @@ -43,7 +43,7 @@ static struct osmo_bsc_data *osmo_bsc_data(struct vty *vty) static struct osmo_msc_data *osmo_msc_data(struct vty *vty) { - return osmo_msc_data_find(bsc_gsmnet, (int) vty->index); + return osmo_msc_data_find(bsc_gsmnet, (long int) vty->index); } static struct cmd_node bsc_node = { @@ -70,7 +70,7 @@ DEFUN(cfg_net_msc, cfg_net_msc_cmd, return CMD_WARNING; } - vty->index = (void *) index; + vty->index = (void *)(long int)index; vty->node = MSC_NODE; return CMD_SUCCESS; } diff --git a/openbsc/tests/libiudummy/iudummy.c b/openbsc/tests/libiudummy/iudummy.c index 54d2c0fd8..7c5129b33 100644 --- a/openbsc/tests/libiudummy/iudummy.c +++ b/openbsc/tests/libiudummy/iudummy.c @@ -4,6 +4,10 @@ #include #include +struct msgb; +struct ue_conn_ctx; +struct gsm_auth_tuple; + int iu_tx(struct msgb *msg, uint8_t sapi) { LOGP(DLGLOBAL, LOGL_INFO, "iu_tx() dummy called, NOT transmitting %d bytes: %s\n",