diff mbox

[3/3] gsm340_rx_tpdu: comment-out two unused vars

Message ID 1456341367-15394-4-git-send-email-nhofmeyr@sysmocom.de
State Accepted
Headers show

Commit Message

Neels Hofmeyr Feb. 24, 2016, 7:16 p.m. UTC
Kills two compiler warnings.
---
 openbsc/src/libmsc/gsm_04_11.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
diff mbox

Patch

diff --git a/openbsc/src/libmsc/gsm_04_11.c b/openbsc/src/libmsc/gsm_04_11.c
index 266cd4d..e3d261e 100644
--- a/openbsc/src/libmsc/gsm_04_11.c
+++ b/openbsc/src/libmsc/gsm_04_11.c
@@ -357,7 +357,7 @@  static int gsm340_rx_tpdu(struct gsm_subscriber_connection *conn, struct msgb *m
 	uint8_t *smsp = msgb_sms(msg);
 	struct gsm_sms *gsms;
 	unsigned int sms_alphabet;
-	uint8_t sms_mti, sms_mms, sms_vpf, sms_rp;
+	uint8_t sms_mti, sms_vpf;
 	uint8_t *sms_vp;
 	uint8_t da_len_bytes;
 	uint8_t address_lv[12]; /* according to 03.40 / 9.1.2.5 */
@@ -371,11 +371,14 @@  static int gsm340_rx_tpdu(struct gsm_subscriber_connection *conn, struct msgb *m
 
 	/* invert those fields where 0 means active/present */
 	sms_mti = *smsp & 0x03;
-	sms_mms = !!(*smsp & 0x04);
 	sms_vpf = (*smsp & 0x18) >> 3;
 	gsms->status_rep_req = (*smsp & 0x20);
 	gsms->ud_hdr_ind = (*smsp & 0x40);
+	/* This used to be unused code, avoid a recurring compiler warning:
+	uint8_t sms_mms, sms_rp;
+	sms_mms = !!(*smsp & 0x04);
 	sms_rp  = (*smsp & 0x80);
+	*/
 
 	smsp++;
 	gsms->msg_ref = *smsp++;