From cfee952e23244dc92a3896e66f2463240983f2c7 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Fri, 4 Apr 2014 12:43:08 +0200 Subject: gprs: Fix compiler warnings in gprs_sndcp.c MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit CC gprs_sndcp.o gprs_sndcp.c: In function ‘defrag_input’: gprs_sndcp.c:188:25: warning: variable ‘scomph’ set but not used [-Wunused-but-set-variable] struct sndcp_comp_hdr *scomph = NULL; ^ gprs_sndcp.c: In function ‘sndcp_llunitdata_ind’: gprs_sndcp.c:512:11: warning: variable ‘npdu_num’ set but not used [-Wunused-but-set-variable] uint16_t npdu_num; ^ gprs_sndcp.c: At top level: gprs_sndcp.c:565:12: warning: ‘sndcp_ll_reset_ind’ defined but not used [-Wunused-function] static int sndcp_ll_reset_ind(struct gprs_sndcp_entity *se) ^ gprs_sndcp.c:573:12: warning: ‘sndcp_ll_status_ind’ defined but not used [-Wunused-function] static int sndcp_ll_status_ind() ^ --- openbsc/src/gprs/gprs_sndcp.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'openbsc') diff --git a/openbsc/src/gprs/gprs_sndcp.c b/openbsc/src/gprs/gprs_sndcp.c index 853f8dbc9..98da4aea8 100644 --- a/openbsc/src/gprs/gprs_sndcp.c +++ b/openbsc/src/gprs/gprs_sndcp.c @@ -185,7 +185,6 @@ static int defrag_input(struct gprs_sndcp_entity *sne, struct msgb *msg, uint8_t unsigned int len) { struct sndcp_common_hdr *sch; - struct sndcp_comp_hdr *scomph = NULL; struct sndcp_udata_hdr *suh; uint16_t npdu_num; uint8_t *data; @@ -193,7 +192,6 @@ static int defrag_input(struct gprs_sndcp_entity *sne, struct msgb *msg, uint8_t sch = (struct sndcp_common_hdr *) hdr; if (sch->first) { - scomph = (struct sndcp_comp_hdr *) (hdr + 1); suh = (struct sndcp_udata_hdr *) (hdr + 1 + sizeof(struct sndcp_common_hdr)); } else suh = (struct sndcp_udata_hdr *) (hdr + sizeof(struct sndcp_common_hdr)); @@ -509,7 +507,7 @@ int sndcp_llunitdata_ind(struct msgb *msg, struct gprs_llc_lle *lle, struct sndcp_comp_hdr *scomph = NULL; struct sndcp_udata_hdr *suh; uint8_t *npdu; - uint16_t npdu_num; + uint16_t npdu_num __attribute__((unused)); int npdu_len; sch = (struct sndcp_common_hdr *) hdr; @@ -561,6 +559,7 @@ int sndcp_llunitdata_ind(struct msgb *msg, struct gprs_llc_lle *lle, return sgsn_rx_sndcp_ud_ind(&sne->ra_id, lle->llme->tlli, sne->nsapi, msg, npdu_len, npdu); } +#if 0 /* Section 5.1.2.1 LL-RESET.ind */ static int sndcp_ll_reset_ind(struct gprs_sndcp_entity *se) { @@ -577,7 +576,6 @@ static int sndcp_ll_status_ind() return 0; } -#if 0 static struct sndcp_state_list {{ uint32_t states; unsigned int type; -- cgit v1.2.3