Skip to content
This repository has been archived by the owner on Jun 24, 2023. It is now read-only.

Commit

Permalink
[python] implemented sub-interpreter support
Browse files Browse the repository at this point in the history
  • Loading branch information
hugsy committed Jun 11, 2015
1 parent 8fb91bf commit 1421af6
Show file tree
Hide file tree
Showing 5 changed files with 225 additions and 173 deletions.
2 changes: 1 addition & 1 deletion core.c
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ static int proxenet_apply_plugins(request_t *request)
unsigned long msec = (tend.tv_usec-tstart.tv_usec)/1000;
unsigned long usec = (tend.tv_usec-tstart.tv_usec)%1000;

xlog(LOG_DEBUG, "[%s] '%s:%s' executed in %lusec, %lums, %luus\n",
xlog(LOG_DEBUG, "[%s] '%s:%s' executed in %dsec, %dms, %dus\n",
supported_plugins_str[p->type], p->name,
request->type==REQUEST?CFG_REQUEST_PLUGIN_FUNCTION:CFG_RESPONSE_PLUGIN_FUNCTION,
sec, msec, usec);
Expand Down
6 changes: 3 additions & 3 deletions plugin-java.c
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ int proxenet_java_load_file(plugin_t* plugin)
return -1;
}

plugin->class = (void*)jcls;
plugin->internal = (void*)jcls;

#ifdef DEBUG
xlog_java(LOG_DEBUG, "Class '%s' jcls=%#lx\n", plugin->name, jcls);
Expand Down Expand Up @@ -207,11 +207,11 @@ static char* proxenet_java_execute_function(plugin_t* plugin, request_t *request

if (request->type==REQUEST){
meth = CFG_REQUEST_PLUGIN_FUNCTION;
jcls = (jclass)plugin->class;
jcls = (jclass)plugin->internal;
jmid = (jmethodID)plugin->pre_function;
} else {
meth = CFG_RESPONSE_PLUGIN_FUNCTION;
jcls = (jclass)plugin->class;
jcls = (jclass)plugin->internal;
jmid = (jmethodID)plugin->post_function;
}

Expand Down

0 comments on commit 1421af6

Please sign in to comment.