From adb11d5f566968a0a12fcd225b5748bce09e0014 Mon Sep 17 00:00:00 2001 From: Fredrik Tolf Date: Sat, 23 Oct 2010 08:31:36 +0200 Subject: [PATCH] python: Changed wmain calling convention. --- python/ashd-wsgi | 2 +- python/ashd/wsgidir.py | 4 ++-- python/scgi-wsgi | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/python/ashd-wsgi b/python/ashd-wsgi index beb39ca..e8f8435 100755 --- a/python/ashd-wsgi +++ b/python/ashd-wsgi @@ -29,7 +29,7 @@ if not modwsgi_compat: if not hasattr(handlermod, "wmain"): sys.stderr.write("ashd-wsgi: handler %s has no `wmain' function\n" % args[0]) sys.exit(1) - handler = handlermod.wmain(args[1:]) + handler = handlermod.wmain(*args[1:]) else: if not hasattr(handlermod, "application"): sys.stderr.write("ashd-wsgi: handler %s has no `application' object\n" % args[0]) diff --git a/python/ashd/wsgidir.py b/python/ashd/wsgidir.py index 335a5d7..e5dee72 100644 --- a/python/ashd/wsgidir.py +++ b/python/ashd/wsgidir.py @@ -54,7 +54,7 @@ def chain(path, env, startreq): entry = mod.entry else: if hasattr(mod.mod, "wmain"): - entry = mod.mod.wmain([]) + entry = mod.mod.wmain() elif hasattr(mod.mod, "application"): entry = mod.mod.application mod.entry = entry @@ -78,5 +78,5 @@ def application(env, startreq): return wsgiutil.simpleerror(env, startreq, 500, "Internal Error", "The server is erroneously configured.") return(exts[ext](path, env, startreq)) -def wmain(argv): +def wmain(*argv): return application diff --git a/python/scgi-wsgi b/python/scgi-wsgi index 4258566..006f375 100755 --- a/python/scgi-wsgi +++ b/python/scgi-wsgi @@ -48,7 +48,7 @@ if not modwsgi_compat: if not hasattr(handlermod, "wmain"): sys.stderr.write("scgi-wsgi: handler %s has no `wmain' function\n" % args[0]) sys.exit(1) - handler = handlermod.wmain(args[1:]) + handler = handlermod.wmain(*args[1:]) else: if not hasattr(handlermod, "application"): sys.stderr.write("scgi-wsgi: handler %s has no `application' object\n" % args[0]) -- 2.11.0