From 2ccca75215b4eeef2a825ca45e1b44d0263628b7 Mon Sep 17 00:00:00 2001 From: Jeff Lenk Date: Tue, 22 Dec 2009 03:55:29 +0000 Subject: [PATCH] FSBUILD-221 - fix several trivial warnings git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16013 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/mod/applications/mod_esf/mod_esf.c | 2 +- src/mod/endpoints/mod_sofia/sofia_glue.c | 2 +- .../mod_spidermonkey_core_db.c | 12 ++++++------ 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/mod/applications/mod_esf/mod_esf.c b/src/mod/applications/mod_esf/mod_esf.c index 34acba5ec2..321fdc7c93 100644 --- a/src/mod/applications/mod_esf/mod_esf.c +++ b/src/mod/applications/mod_esf/mod_esf.c @@ -136,7 +136,7 @@ SWITCH_STANDARD_APP(bcast_function) goto fail; } - if (switch_mcast_hops(socket, mcast_ttl) != SWITCH_STATUS_SUCCESS) { + if (switch_mcast_hops(socket, (uint8_t)mcast_ttl) != SWITCH_STATUS_SUCCESS) { switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(session), SWITCH_LOG_ERROR, "Mutlicast TTL set failed\n"); goto fail; } diff --git a/src/mod/endpoints/mod_sofia/sofia_glue.c b/src/mod/endpoints/mod_sofia/sofia_glue.c index 06527f72d7..e3856c5025 100644 --- a/src/mod/endpoints/mod_sofia/sofia_glue.c +++ b/src/mod/endpoints/mod_sofia/sofia_glue.c @@ -2070,7 +2070,7 @@ switch_status_t sofia_glue_tech_set_codec(private_object_t *tech_pvt, int force) } if (strcasecmp(tech_pvt->read_impl.iananame, tech_pvt->iananame) || tech_pvt->read_impl.samples_per_second != tech_pvt->rm_rate || - tech_pvt->codec_ms != tech_pvt->read_impl.microseconds_per_packet / 1000) { + tech_pvt->codec_ms != (uint32_t)tech_pvt->read_impl.microseconds_per_packet / 1000) { switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->session), SWITCH_LOG_DEBUG, "Changing Codec from %s@%dms to %s@%dms\n", tech_pvt->read_impl.iananame, tech_pvt->read_impl.microseconds_per_packet / 1000, diff --git a/src/mod/languages/mod_spidermonkey_core_db/mod_spidermonkey_core_db.c b/src/mod/languages/mod_spidermonkey_core_db/mod_spidermonkey_core_db.c index 4434bfeae7..2d9530b8b7 100644 --- a/src/mod/languages/mod_spidermonkey_core_db/mod_spidermonkey_core_db.c +++ b/src/mod/languages/mod_spidermonkey_core_db/mod_spidermonkey_core_db.c @@ -288,7 +288,7 @@ static JSBool db_bind_text(JSContext * cx, JSObject * obj, uintN argc, jsval * a { struct db_obj *dbo = JS_GetPrivate(cx, obj); JSBool status; - uint32 param_index = -1; + int32 param_index = -1; char *param_value = NULL; *rval = BOOLEAN_TO_JSVAL(JS_FALSE); @@ -312,7 +312,7 @@ static JSBool db_bind_text(JSContext * cx, JSObject * obj, uintN argc, jsval * a /* convert args */ - status = JS_ValueToECMAUint32(cx, argv[0], ¶m_index); + status = JS_ValueToECMAUint32(cx, argv[0], &(uint32)param_index); switch_assert(status == JS_TRUE); param_value = JS_GetStringBytes(JS_ValueToString(cx, argv[1])); if ((param_index < 1) || (NULL == param_value)) { @@ -334,8 +334,8 @@ static JSBool db_bind_int(JSContext * cx, JSObject * obj, uintN argc, jsval * ar { struct db_obj *dbo = JS_GetPrivate(cx, obj); JSBool status; - uint32 param_index = -1; - uint32 param_value = -1; + int32 param_index = -1; + int32 param_value = -1; *rval = BOOLEAN_TO_JSVAL(JS_FALSE); @@ -356,9 +356,9 @@ static JSBool db_bind_int(JSContext * cx, JSObject * obj, uintN argc, jsval * ar } /* convert args */ - status = JS_ValueToECMAUint32(cx, argv[0], ¶m_index); + status = JS_ValueToECMAUint32(cx, argv[0], &(uint32)param_index); switch_assert(status == JS_TRUE); - status = JS_ValueToECMAUint32(cx, argv[1], ¶m_value); + status = JS_ValueToECMAUint32(cx, argv[1], &(uint32)param_value); switch_assert(status == JS_TRUE); if (param_index < 1) {