aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKeith <keith@rhizomatica.org>2017-08-14 15:11:57 +0200
committerNeels Hofmeyr <neels@hofmeyr.de>2017-08-27 17:40:55 +0200
commita12df55ce7ef8f90b2afee0f7d01b2a7e850f489 (patch)
treeccb1f9e6f826c60af01286ba82e4eebea2617a2a
parentc42b5f0861c1040be6dffad1d73c417f46db9d98 (diff)
LIBMSC: Use sms->text, not sms->user_data to construct report body
gsm_04_11.c sms_report_alloc() Use the sms->text, not the sms->user_data to construct the report body. This also prevents the potential output of non printable characters to the log and or vty. Change-Id: Id51bc9483ad6f52d6da74135605cfd12434c7c96
-rw-r--r--src/libmsc/gsm_04_11.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libmsc/gsm_04_11.c b/src/libmsc/gsm_04_11.c
index f87acea1e..55642aa4a 100644
--- a/src/libmsc/gsm_04_11.c
+++ b/src/libmsc/gsm_04_11.c
@@ -667,7 +667,7 @@ static struct gsm_sms *sms_report_alloc(struct gsm_sms *sms)
len = snprintf((char *)sms_report->user_data,
sizeof(sms_report->user_data),
"id:%.08llu sub:000 dlvrd:000 submit date:YYMMDDhhmm done date:YYMMDDhhmm stat:DELIVRD err:000 text:%.20s",
- sms->id, sms->user_data);
+ sms->id, sms->text);
sms_report->user_data_len = len;
LOGP(DLSMS, LOGL_NOTICE, "%s\n", sms_report->user_data);