[sr-dev] git:master:074c7ce1: smsops: cast to unsigned long, related to commit a61e04757d5f

Henning Westerholt hw at skalatan.de
Wed Sep 25 15:36:13 CEST 2019


Module: kamailio
Branch: master
Commit: 074c7ce165704aaea0d5ec3cd0d920656c1cd255
URL: https://github.com/kamailio/kamailio/commit/074c7ce165704aaea0d5ec3cd0d920656c1cd255

Author: Henning Westerholt <hw at skalatan.de>
Committer: Henning Westerholt <hw at skalatan.de>
Date: 2019-09-25T15:35:47+02:00

smsops: cast to unsigned long, related to commit a61e04757d5f

---

Modified: src/modules/smsops/smsops_impl.c

---

Diff:  https://github.com/kamailio/kamailio/commit/074c7ce165704aaea0d5ec3cd0d920656c1cd255.diff
Patch: https://github.com/kamailio/kamailio/commit/074c7ce165704aaea0d5ec3cd0d920656c1cd255.patch

---

diff --git a/src/modules/smsops/smsops_impl.c b/src/modules/smsops/smsops_impl.c
index be341b13f3..8dfe70163a 100644
--- a/src/modules/smsops/smsops_impl.c
+++ b/src/modules/smsops/smsops_impl.c
@@ -469,7 +469,7 @@ int decode_3gpp_sms(struct sip_msg *msg) {
 		if (!rp_data) {
 			rp_data = (sms_rp_data_t*)pkg_malloc(sizeof(struct _sms_rp_data));
 			if (!rp_data) {
-				LM_ERR("Error allocating %lu bytes!\n", (long)sizeof(struct _sms_rp_data));
+				LM_ERR("Error allocating %lu bytes!\n", (unsigned long)sizeof(struct _sms_rp_data));
 				return -1;
 			}
 		} else {
@@ -846,7 +846,7 @@ int pv_set_sms(struct sip_msg* msg, pv_param_t *param, int op, pv_value_t *val)
 	if (!rp_send_data) {
 		rp_send_data = (sms_rp_data_t*)pkg_malloc(sizeof(struct _sms_rp_data));
 		if (!rp_send_data) {
-			LM_ERR("Error allocating %lu bytes!\n", (long)sizeof(struct _sms_rp_data));
+			LM_ERR("Error allocating %lu bytes!\n", (unsigned long)sizeof(struct _sms_rp_data));
 			return -1;
 		}
 		// Initialize structure:




More information about the sr-dev mailing list