diff --git a/src/mod/endpoints/mod_sofia/sofia_presence.c b/src/mod/endpoints/mod_sofia/sofia_presence.c index 7590b2f6c0..32f6d71d87 100644 --- a/src/mod/endpoints/mod_sofia/sofia_presence.c +++ b/src/mod/endpoints/mod_sofia/sofia_presence.c @@ -1206,11 +1206,11 @@ static int sofia_presence_sub_callback(void *pArg, int argc, char **argv, char * switch_set_string(expires_str, "0"); kill_handle = 1; } else if (exptime > 0) { - switch_snprintf(sstr, sizeof(sstr), "active;expires=%d", exptime); + switch_snprintf(sstr, sizeof(sstr), "active;expires=%u", (unsigned)exptime); } else { - long delta = exptime * -1; - switch_snprintf(sstr, sizeof(sstr), "active;expires=%d", delta); - switch_snprintf(expires_str, sizeof(expires_str), "%d", delta); + unsigned delta = (unsigned) (exptime * -1); + switch_snprintf(sstr, sizeof(sstr), "active;expires=%u", delta); + switch_snprintf(expires_str, sizeof(expires_str), "%u", delta); nua_dialog_usage_set_refresh_range(nh->nh_ds->ds_usage, delta, delta); } diff --git a/src/switch_ivr_originate.c b/src/switch_ivr_originate.c index e45c982b82..e9a5f4dcec 100644 --- a/src/switch_ivr_originate.c +++ b/src/switch_ivr_originate.c @@ -1326,11 +1326,11 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_originate(switch_core_session_t *sess ringback.fh = &ringback.fhb; } else if (!strncasecmp(ringback_data, "silence", 7)) { - const char *p = ringback_data + 7; - if (*p == ':') { - p++; - if (p) { - ringback.silence = atoi(p); + const char *c = ringback_data + 7; + if (*c == ':') { + c++; + if (c) { + ringback.silence = atoi(c); } } if (ringback.silence <= 0) {