mod_python & mod_spidermonkey: Fix for -Wunused-but-set-variable required compiler
This commit is contained in:
parent
cf1494f773
commit
ab02493b9d
|
@ -77,13 +77,11 @@ static void eval_some_python(const char *funcname, char *args, switch_core_sessi
|
||||||
char *dupargs = NULL;
|
char *dupargs = NULL;
|
||||||
char *argv[2] = { 0 };
|
char *argv[2] = { 0 };
|
||||||
int argc;
|
int argc;
|
||||||
int lead = 0;
|
|
||||||
char *script = NULL;
|
char *script = NULL;
|
||||||
PyObject *module = NULL, *sp = NULL, *stp = NULL, *eve = NULL;
|
PyObject *module = NULL, *sp = NULL, *stp = NULL, *eve = NULL;
|
||||||
PyObject *function = NULL;
|
PyObject *function = NULL;
|
||||||
PyObject *arg = NULL;
|
PyObject *arg = NULL;
|
||||||
PyObject *result = NULL;
|
PyObject *result = NULL;
|
||||||
switch_channel_t *channel = NULL;
|
|
||||||
char *p;
|
char *p;
|
||||||
|
|
||||||
if (str) {
|
if (str) {
|
||||||
|
@ -105,8 +103,6 @@ static void eval_some_python(const char *funcname, char *args, switch_core_sessi
|
||||||
|
|
||||||
script = strdup(switch_str_nil(argv[0]));
|
script = strdup(switch_str_nil(argv[0]));
|
||||||
|
|
||||||
lead = 1;
|
|
||||||
|
|
||||||
if ((p = strstr(script, "::"))) {
|
if ((p = strstr(script, "::"))) {
|
||||||
*p = '\0';
|
*p = '\0';
|
||||||
p += 2;
|
p += 2;
|
||||||
|
@ -157,7 +153,6 @@ static void eval_some_python(const char *funcname, char *args, switch_core_sessi
|
||||||
}
|
}
|
||||||
|
|
||||||
if (session) {
|
if (session) {
|
||||||
channel = switch_core_session_get_channel(session);
|
|
||||||
sp = mod_python_conjure_session(module, session);
|
sp = mod_python_conjure_session(module, session);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -513,12 +513,12 @@ static JSBool odbc_setProperty(JSContext * cx, JSObject * obj, jsval id, jsval *
|
||||||
|
|
||||||
static JSBool odbc_getProperty(JSContext * cx, JSObject * obj, jsval id, jsval * vp)
|
static JSBool odbc_getProperty(JSContext * cx, JSObject * obj, jsval id, jsval * vp)
|
||||||
{
|
{
|
||||||
int param;
|
//int param;
|
||||||
char *name = JS_GetStringBytes(JS_ValueToString(cx, id));
|
char *name = JS_GetStringBytes(JS_ValueToString(cx, id));
|
||||||
|
|
||||||
/* numbers are our props anything else is a method */
|
/* numbers are our props anything else is a method */
|
||||||
if (name[0] >= 48 && name[0] <= 57) {
|
if (name[0] >= 48 && name[0] <= 57) {
|
||||||
param = atoi(name);
|
// param = atoi(name);
|
||||||
} else {
|
} else {
|
||||||
return JS_TRUE;
|
return JS_TRUE;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue