mod_python & mod_spidermonkey: Fix for -Wunused-but-set-variable required compiler

This commit is contained in:
Marc Olivier Chouinard 2011-04-22 22:03:40 -04:00
parent cf1494f773
commit ab02493b9d
2 changed files with 2 additions and 7 deletions

View File

@ -77,13 +77,11 @@ static void eval_some_python(const char *funcname, char *args, switch_core_sessi
char *dupargs = NULL;
char *argv[2] = { 0 };
int argc;
int lead = 0;
char *script = NULL;
PyObject *module = NULL, *sp = NULL, *stp = NULL, *eve = NULL;
PyObject *function = NULL;
PyObject *arg = NULL;
PyObject *result = NULL;
switch_channel_t *channel = NULL;
char *p;
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]));
lead = 1;
if ((p = strstr(script, "::"))) {
*p = '\0';
p += 2;
@ -157,7 +153,6 @@ static void eval_some_python(const char *funcname, char *args, switch_core_sessi
}
if (session) {
channel = switch_core_session_get_channel(session);
sp = mod_python_conjure_session(module, session);
}

View File

@ -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)
{
int param;
//int param;
char *name = JS_GetStringBytes(JS_ValueToString(cx, id));
/* numbers are our props anything else is a method */
if (name[0] >= 48 && name[0] <= 57) {
param = atoi(name);
// param = atoi(name);
} else {
return JS_TRUE;
}