From 785e1dbf83ffb5a673cf175cb8a0970cd36f4dda Mon Sep 17 00:00:00 2001 From: "roberto@debian32" Date: Thu, 10 Nov 2011 15:33:19 +0100 Subject: [PATCH] re-thinked remap-modifier --- uwsgi.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/uwsgi.c b/uwsgi.c index c2fc854c..c6320bdd 100644 --- a/uwsgi.c +++ b/uwsgi.c @@ -2831,15 +2831,8 @@ skipzero: int rm_src = atoi(map); int rm_dst = atoi(colon + 1); up_tmp = uwsgi.p[rm_dst]; - uwsgi.p[rm_dst] = uwsgi.p[rm_src]; - uwsgi.p[rm_src] = up_tmp; - // fix rpc - for (i = 0; i < uwsgi.shared->rpc_count; i++) { - if (uwsgi.shared->rpc_table[i].modifier1 == rm_src) - uwsgi.shared->rpc_table[i].modifier1 = rm_dst; - else if (uwsgi.shared->rpc_table[i].modifier1 == rm_dst) - uwsgi.shared->rpc_table[i].modifier1 = rm_src; - } + uwsgi.p[rm_dst]->request = uwsgi.p[rm_src]->request; + uwsgi.p[rm_src]->after_request = up_tmp->after_request; } map = strtok(NULL, ","); }